Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support setup.cfg for Python packages #459

Open
brainwane opened this issue Jul 21, 2019 · 4 comments
Open

Support setup.cfg for Python packages #459

brainwane opened this issue Jul 21, 2019 · 4 comments

Comments

@brainwane
Copy link

On PyPI, packages sometimes include requirements in the install_requires section of the setup.cfg file. Examples (from @jaraco who is a Tidelift lifter):

It might be a good idea to fix this in one fell swoop along with #76.

@brainwane
Copy link
Author

(In particular I noticed this because fogbugz-bis heavily depends on Beautiful Soup, which is also a Tidelift-supported project, yet https://libraries.io/pypi/fogbugz_bis does not reflect that dependency.)

@jaraco
Copy link

jaraco commented Jul 21, 2019

+1 to supporting more than just setup.py.

But I wonder if there's perhaps a better place to support this need. Both setup.py and setup.cfg (and other PEP 517 builders) will produce a package (wheel) with metadata. Perhaps the better model would be to extract the install requirements from the built-package's metadata. If you need it from source, you could use something like pep517#48... or if you could rely on published wheels, it should be sufficient to inspect them directly with importlib_metadata.

@astrofrog
Copy link

astrofrog commented Jul 23, 2019

+1 on parsing setup.cfg, many projects are using this these days.

I'm not sure what your policy is on optional dependencies, but setup.cfg can also have sections to define extras_require, e.g https://github.com/astropy/astropy/blob/master/setup.cfg#L47 - it would be great to parse these too if possible.

@brainwane
Copy link
Author

Another liftable package that uses setup.cfg: flake8. Seems to have zero dependencies on libraries.io.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants