no module named packaging.version
By John Peck •
I installed Ubuntu 14.04 yesterday and installed pip by the commandsudo apt-get install python-pip,
later when I am trying to install other packages through pip or trying to check the pip version, I am getting the following error.
Traceback (most recent call last): File "/usr/bin/pip", line 5, in module from pkg_resources import load_entry_point File "/home/abhi/.local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 70, in module import packaging.version
ImportError: No module named packaging.versionI tried by installing pip3, but that also gives the same error.
12 Answers
I solved the above problem by installing pip by the following command
python -m pip install -U pipNow pip is working fine..
2What worked for me was to reinstall pip using the get-pip.py script, as described here:
sudo apt-get purge python-pip python-setuptools
curl -O
sudo python get-pip.py