What does "pip install" do?

Chris Angelico rosuav at gmail.com
Mon Jan 12 23:46:46 CET 2015


On Tue, Jan 13, 2015 at 9:35 AM, Fabien <fabien.maussion at gmail.com> wrote:
>
> I've learned a lot today about python packaging and stuff, thanks to a
> couple of good websites. I've learned how to install a package from PyPi
> with pip, choose which version, upgrade it, uninstall it, use virtualenv,
> BUT I'm still asking myself: what does "pip install" *concretely* do on my
> virtual environment?

As far as I know, it's equivalent to three steps:

1) Download the appropriate version of a package (the latest, if you
didn't say otherwise)
2) Extract that package
3) Run 'python setup.py'.

What setup.py does is up to the package, but for a pure-Python package
it should simply create something in site-packages. It might do a lot
more, though - compiling C or Fortran code, for instance.

ChrisA



More information about the Python-list mailing list