On 26 February 2015 at 18:23, Ethan Furman <et...@stoneleaf.us> wrote: > On 02/26/2015 09:28 AM, Glenn Linderman wrote: >> On 2/26/2015 9:05 AM, Paul Moore wrote: > >>> ``create_archive(source, target=None, interpreter=None, main=None)`` >>> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ >>> >>> Create an application archive from *source*. The source can be any >>> of the following: >>> >>> * The name of a directory, in which case a new application archive >>> will be created from the content of that directory. >>> * The name of an existing application archive file, in which case the >>> file is copied to the target. The file name should include the >>> ``.pyz`` extension, if required. >> >> Or ".pyzw", I presume. > > Hmm -- can the py launcher handle a `#!pythonw` line to properly launch a > .pyz (or .py) file?
No. The launcher doesn't handle pythonw, because it won't do what you expect. On Windows, the difference between a GUI and a console program is baked into the executable (the "subsystem" field in the exe file header). That's why we have python/pythonw and py/pyw executables. A .pyz with a #!pythonw shebang would be run by py.exe, which would launch pythonw.exe. So if you double click the file, a console window will open (for py.exe) but the script won't use it (because it's being run by pythonw). So you'll have a useless console window hanging round. Paul _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com