Closed dmr closed 11 years ago
There's not an API for that (yet!). As the code is currently written, a normal pip requirement (that would typically result in a pypi search) will have the "name", "extras" and "specs" fields only. Checking for "vcs" is not foolproof since a requirement could be an absolute path to a file or a URL that doesn't point to version control.
Thanks for the quick response. I ended up using pkg_resources to decide that for me: https://github.com/dmr/py3compat_checker/blob/master/app.py#L116
The app is probably full of bugs like the absolute path problem but it worked for what I needed.
Requirements parser uses the same underlying library. Glad to hear it worked out.
In the example requirements-parser is parsed as "requirements".
Another package that is provided by Pypi has a similar structure:
--> I assume that I can test
to see if a package is provided by Pypi. Is that correct or do you know a better way?