3
votes

I just finished installing the latest stable version of python via Homebrew.

$ brew install python3

Everything works fine. I would like to install packages, for example PyMongo. I don't have pip.

$ pip -bash: pip: command not found

and there is no Homebrew formulae for it:

$ brew install PyMongo

brew install PyMongo Error: No available formula for pymongo Searching formulae... Searching taps...

Any idea what's the best way to install PyMongo on OS X when Python was installed via Homebrew. Thank you!

1
How about installing pip via homebrew and then installing pymongo via pip?dursk
Well, I'm not sure if this is the best way but I managed to install it with: $ python3 -m easy_install pymongoZoltan King

1 Answers

6
votes

Use pip3. The "caveats" text you see when you run brew info python3 was printed for you after python3 was installed; that text is frequently helpful! It reads:

You can install Python packages with

pip3 install <package>

They will install into the site-package directory

/usr/local/lib/python3.4/site-packages