Originally reported by: jaraco (Bitbucket: jaraco, GitHub: jaraco)
With the inception of Vinay Sajip's pylauncher and its defacto inclusion in Python 3.3 (with backward-support for other Python versions), the need for Setuptools to provide launcher executables in these environments is now diminished.
Setuptools should now be able to create simple '.py' scripts, exactly as it does on Unix except with the additional .py or .pyw extension.
One necessity to make this work smoothly will be for .py and .pyw to be registered with the pylauncher and for those extensions to be present in PATHEXT. Perhaps Setuptools can help facilitate that support.
While I believe leveraging the pylauncher is the right thing to do, it will need to be done with care and a smooth transition planned. Here's what I have in mind:
- Refactor the code to allow for two modes (exe launchers and native .py launchers).
- Initially enable the native-only launcher support by way of an environment variable, allowing users to adopt the future behavior voluntarily and not by default.
- After some period of exposure and addressing any issues, deprecate the exe launchers and make native .py launchers the default. Allow exe support to be enabled by a different environment variable.
- Consider removing exe support.
Originally reported by: jaraco (Bitbucket: jaraco, GitHub: jaraco)
With the inception of Vinay Sajip's pylauncher and its defacto inclusion in Python 3.3 (with backward-support for other Python versions), the need for Setuptools to provide launcher executables in these environments is now diminished.
Setuptools should now be able to create simple '.py' scripts, exactly as it does on Unix except with the additional .py or .pyw extension.
One necessity to make this work smoothly will be for .py and .pyw to be registered with the pylauncher and for those extensions to be present in PATHEXT. Perhaps Setuptools can help facilitate that support.
While I believe leveraging the pylauncher is the right thing to do, it will need to be done with care and a smooth transition planned. Here's what I have in mind: