6

I upgraded to the new version of Pycharm. In the terminal, it says bash-3.2$ instead of my username. When I tried to install a library, it said that pip command is not found:

bash: pip: command not found

So I installed pip:

bash-3.2$ sudo easy_install pip
Searching for pip
Best match: pip 8.1.2
pip 8.1.2 is already the active version in easy-install.pth
Installing pip script to /usr/local/bin
Installing pip3.5 script to /usr/local/bin
Installing pip3 script to /usr/local/bin

Using /Library/Python/2.7/site-packages
Processing dependencies for pip
Finished processing dependencies for pip</i>

Okay, now all I have to do is use pip to install a library, right?

But then, this happens:

bash-3.2$ pip install pandas
bash: pip: command not found

I don't understand what I have to do to actually install pip. Or should I use sudo easy_install [library]?

FooF
  • 4,323
  • 2
  • 31
  • 47
Imperator123
  • 599
  • 2
  • 11
  • 25

2 Answers2

4

I know that this is not precisely what you're asking, but PyCharm has its own built-in package manager. You should not have to use pip manually.

File->Settings->Project Interpreter https://www.jetbrains.com/help/pycharm/2016.3/installing-uninstalling-and-upgrading-packages.html

there you can manage the installed packages for the selected Python interpreter or virtualenv.

Irmen de Jong
  • 2,739
  • 1
  • 14
  • 26
1

Run this command on your terminal. pip will be installed without any issue.

sudo [your package manager] install python-pip python-dev build-essential

If it is not solved. The problem might be PATH problem. Type echo $PATH on terminal. There should be /usr/local/bin in the output. If it is not type PATH=$PATH:/usr/local/bin to add /usr/local/bin to PATH

Vibhutha Kumarage
  • 1,372
  • 13
  • 26