I don’t like the PEP, as I said above, but assuming that it is going to be done, why not borrow the same syntax as encoding comments? Namely #-*- requirements: numpy, scipy, pandas, rich -*-
.
I can also imagine
__requirements__ = """
numpy
scipy
pandas
rich
"""
or even
__metadata__ = """
[project.dependencies]
...
"""
(the latter making it an “inline pyproject.toml”).