On 2020-11-24 16:47, Chris Angelico wrote:
On Wed, Nov 25, 2020 at 10:29 AM Brendan Barnwell email@example.com wrote:
On 2020-11-24 00:05, Chris Angelico wrote:
I'm still confused what the point is of a zipapp, if it can't be a proper point and click GUI thing, and it can't use any compiled extensions. How it is it better than a console_script and a pip-installed package??
It CAN be a proper point-and-click GUI thing. You can have a fully executable Python script if it has no dependencies (just distribute a single .py file with a shebang at the top), and if you can't do that, bundle it into a .pyz with zipapp and, again, put a shebang for posix platforms. Windows, if the py.exe launcher is installed, will happily let you double-click on a .py or .pyz and it'll run just fine.
I think by "proper point-and-click GUI thing" he meant the app itself
is a GUI app, not just "can be launched via the OS GUI". At least, that is what I would mean by that, and that is what can't be done without C extensions, because most GUI toolkits require C extensions.
Python ships with one GUI toolkit (Tkinter). If you can't install anything else, you at least get that.
That's not even close to sufficient.
I realize that we're diverging a bit from the original thread here, but basically my position on this is that what would be good is a full solution. Not another half solution or three-quarters solution. What I mean by a full solution is I should be able to write any Python app using any libraries I want and anyone can install it on any OS without knowing anything about Python or any of those libraries, with no limitations except that the libraries my app uses have to exist for the platform they install it on. So if, say, PyQt actually isn't available for your platform, okay, you're out of luck, but if it is available there should be no packaging/distribution/installation obstacle that prevents it from being used in an app that appears to the user as an ordinary native OS app.
These other alternatives of "well no but you can do X. . ." are, from my perspective, pointless. There are already lots of half-solutions that allow some combinations of things but not others, and we don't need another one of those. What we need is a full solution. The great thing about Python is ALL the things you can with Python, and what would be good is a solution that lets you do ALL the things you can do with Python, but as regular transparently-OS-installable-and-usable apps.