Back to Python#Installation

See also virtualenv


A tool for installing and managing Python packages.

1. pip vs easy_install

2. Installation

sudo python

3. Useful Commands

3.1. pip upgrade to 1.3.1

pip --version
pip install -U pip

3.2. install a specific version

pip install 'SomeProject==1.4'
pip install 'SomeProject>=1,<2'
pip install 'SomeProject~=1.4.2'

3.3. local install

#download to local but can not directly use
pip install fabric -d /srv/fabric/pip-cache/ --timeout 1000
#Using download cache next time
pip install -U fabric --download-cache /srv/fabric/pip-cache/

3.4. HashMismatch: Bad md5 hash for package

Bad md5 hash for package (from
Storing debug log for failure in /Users/liyan/.pip/pip.log

Found link (from, version: 1.9.3

j tmp
(env)➜  tmp  wget
(env)➜  tmp  md5sum numpy-1.9.3.tar.gz 
7c321721ffc62c25bc854b8addf42f20  numpy-1.9.3.tar.gz ##match md5
(env)➜  tmp  pip install  numpy-1.9.3.tar.gz
Successfully installed numpy
Cleaning up...

4. Useful Packages

4.1. moin & uwsgi

➜  ~  pip search uwsgi
uWSGI                     - The uWSGI server

➜  fabric  pip search moin
moin                      - MoinMoin 1.9.2 is an easy to use, full-featured
                            and extensible wiki software package
editmoin                  - Edit Moin pages remotely with your preferred
moomin                    - Moinmoin client

5. Reference

MainWiki: pip (last edited 2013-07-10 19:36:01 by twotwo)