0 votes
1 view
in Python by (19.5k points)

I downloaded pip and ran python setup.py install and everything worked just fine. The very next step in the tutorial is to run pip install <lib you want> but before it even tries to find anything online I get an error "bash: pip: command not found".

This is on Mac OS X, which I'm new too, so I'm assuming there's some kind of path setting that was not set correctly when I ran setup.py. How can I investigate further? What do I need to check to get a better idea of the exact cause of the problem?

I also tried installing Python 2.7 for Mac in the hopes that the friendly install process would do any housekeeping like editing PATH and whatever else needs to be happy for everything to work according to the tutorials, but this didn't work. After installing is running 'python' still ran Python 2.6 and PATH was not updated.

1 Answer

0 votes
by (46.1k points)

To get rid of the error "bash: pip: command not found" you can use sudo easy_install pip command or if you are a Python 2.6 user then you can use the sudo easy_install-2.6 pip command this will solve your issue.

The above commands install the pip using the default python package installer system which saves you to do the manual set-up all at the time.

...