To me the logical solution is something like Replit, where your arbitrary programming environment is running off-device. You want to program Go or Python on your iPad? Okay, but the actual code is executing in some cloud machine. Apple should be happy with that, and it'll be a lot easier to maintain all this stuff off-device anyway, than on iPads, where nobody else is maintaining a toolchain.
Of course that doesn't work with a "one-time-purchase" business model....