I'm trying to install and use python for the first time, but I'm having problems using extern librairies.
/usr/bin/python /path/core/__init__.py
Traceback (most recent call last):
File "/Users/fabienlamarque/Downloads/RedditAPI/core/__init__.py", line 6, in <module>
import requests
ImportError: No module named requests
Source code :
import requests
r = requests.get(r'path/.json')
As I surfed around trying to find answers, I found some people telling me to use pip, I indeed used pip and pip3 (with python 2.7.5 and python 3.4.2), the answer is always:
$ pip install requests
Requirement already satisfied (use --upgrade to
upgrade): requests in /usr/local/lib/python2.7/site-packages
Cleaning up...
Which seems like a good thing, I forced the reinstallation of the module several times, but I always have the same problem. My IDE tells me "No module named 'requests'" though.
What did I miss?
Thanks
/usr/local/bin/pythonbut are using/usr/bin/python?virtualenvs, which make managing which packages are available for a specific project much easier.python(and hit enter) in the shell?