I don’t think that use case is being dismissed, it would definitely make sense for project management tools that can run projects to also be able to run single-file scripts.
The pushback seems to be on the suggestion that we need all the capabilities (and complexity) of pyproject.toml
(or even just the standard project
metadata fields), when it’s not clear that anything beyond dependencies
(and maybe requires-python
) would make sense for quick scripts that will not be distributed on PyPI or installed as a dependency.
If pyproject.toml
can be embeded in a single-file script, then all tools that read configuration might now get requests to read their configuration from a script instead of a separate file. If only dependencies can be embeded in scripts, then tools that run scripts will get requests to support that, but otherwise the current configuration method remains the same. By the time you need all the features of pyproject.toml
, you may as well write a pyproject.toml
next to the script file, but that’s not needed in the case being described here.