News for hackers. Stuff that matters.
Re:BeeWare – write Python, run everywhere using native UIs by fiatjaf on Sunday February 06, 2022 @06:00PM (#30237957)
What if instead of trying to make standalone programs that run everywhere someone took the approach the browser took, but more on the native side?

Make a runtime that can run a bunch of quasi-native code and make it download code from URLs and execute that.

The experience for the user would be to type "myapp.com" on the URL bar and then get a full native app running inside that browser window -- except instead of bloated JavaScript it would be this new language thing with more powerful native-like APIs and without 32 years of bloated history on its back.

I'm sorry if this is too confusing.

Re:BeeWare – write Python, run everywhere using native UIs by tyingq on Sunday February 06, 2022 @07:49PM (#30238762)
Unfortunately, not an option for iPhones:

3.3.2 An Application may not download or install executable code. Interpreted code may only be used in an Application if all scripts, code and interpreters are packaged in the Application and not downloaded

You would have to ship a new copy of it with each application.

Re:BeeWare – write Python, run everywhere using native UIs by d0mine on Monday February 07, 2022 @11:56AM (#30247504)
There is Pythonista 3 for iOS which allows you to deploy code that is not shipped with the app e.g., it can be used to implement "download audio" button for youtube for iphone (and other supported by youtube-dl video sites)
Re:BeeWare – write Python, run everywhere using native UIs by skaphy on Sunday February 06, 2022 @06:11PM (#30238049)
The program in the new language needs to be translated to native Android and iOS code directly in the "app-browser" right?

Your idea sounds really interesting, but I imagine it being hard to combine the two different frameworks. Especially UI elements.

Re:BeeWare – write Python, run everywhere using native UIs by fiatjaf on Sunday February 06, 2022 @06:28PM (#30238183)
No, it would run in a VM. Just like JavaScript of current browsers, but better.
Re:BeeWare – write Python, run everywhere using native UIs by ajwillia_ms on Monday February 07, 2022 @01:35PM (#30249016)
Apple won't allow that. The only interpreted code is JS and must run on the built-in engine. Plus "dynamically added" code/content must first be approved by Apple or your app can be revoked. Basically there is no shortcut here. Which is why the OP and others like Fyne (https://fyne.io) are taking the approach of write once, compile for anywhere.