How can I download a specific wheel from a package listed on PyPi? I'm assuming I would use wget
or curl
, but I'm not sure of which arguments to use.
PyPI is known to be hard to introspect. Fortunately, the Debian project is used to scan FTP directories for new versions, and set up a solution to workaround this. It is documented at https://wiki.debian.org/debian/watch#PyPI
For exemple, if you access https://pypi.debian.net/pip/, you will have in long list of release. And as you wish, you can directly download a tarball without knowing its checksum, using curl:
$ curl -LO https://pypi.debian.net/pip/pip-18.1.tar.gz
Note that, even if it's not listed, you can download the wheel. But you may need to construct the URL.
$ curl -LO https://pypi.debian.net/pip/pip-18.1-py2.py3-none-any.whl
If you find some tricks around this solution, feel free to share it !
Update 2021: PyPI package pages have a section #files
where you can conveniently download the .whl you'd like
https://pypi.org/project/<package-name>/#files
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With