ImportError No module named pip when trying to install packages

0 votes

I selected 'install setuptools', then 'install pip'. Now if I try and do anything with pip I get the following:

  ciaran@ciaran-desktop:~/pycharm/bin$ pip
  Traceback (most recent call last):
  File "/usr/local/bin/pip", line 9, in <module>
    load_entry_point('pip==1.4.1', 'console_scripts', 'pip')()
  File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 357, in load_entry_point
   """Does the package's distribution contain the named metadata?"""
  File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 2394, in load_entry_point

  File "build/bdist.linux-x86_64/egg/pkg_resources.py", line 2108, in load

  ImportError: No module named pip

I have tried on python 2.7.5 and 3.3.2 and both yield the same results.

Edit: The above output is from the terminal. PyCharm outputs the following:

Error: Python package management tool 'pip' not found 
May 27, 2020 in Python by kartik
• 37,520 points
13,847 views

1 answer to this question.

0 votes

Hello @kartik,

I found that on Ubuntu, pip will not always set read and execute permissions for the modules it installs. My solution is to always run this shell script:

sudo chmod -R a+rX /usr/lib/python*/dist-packages/
sudo chmod -R a+rX /usr/local/lib/python*/dist-packages/
sudo chmod a+rX /usr/bin/*
sudo chmod a+rX /usr/local/bin/*

Hope this work!

answered May 27, 2020 by Niroj
• 82,840 points

Related Questions In Python

0 votes
1 answer
+1 vote
3 answers
0 votes
1 answer
0 votes
1 answer

how to solve the error : "ImportError: No module named Tkinter" in python.

Hi@Umama, If you are using Linux system, then ...READ MORE

answered Apr 27, 2020 in Python by MD
• 95,460 points
13,458 views
0 votes
2 answers
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 7, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 4,434 views
0 votes
1 answer
0 votes
1 answer

What is the equivalent to a JavaScript setInterval/setTimeout in Android/Java?

Hii @kartik, As always with Android there's lots ...READ MORE

answered May 26, 2020 in Java by Niroj
• 82,840 points
3,637 views
0 votes
1 answer

How to Install Python packages from local file system folder to virtualenv with pip?

Hello @kartik, You can try the code below: pip ...READ MORE

answered May 12, 2020 in Python by Niroj
• 82,840 points

edited Oct 7, 2021 by Sarfaraz 13,330 views
0 votes
2 answers

Python error “ImportError: No module named”

use the dir() function for particular import ...READ MORE

answered Jun 6, 2020 in Python by sahil
• 500 points
16,051 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP