I'm trying to use requests and oauthlib requests, and right now I'm just trying to skip dead simple Twitter to check the credentials that they use in the documentation for request_oauthlib to confirm that I have the basics. I got "pip install requests requests_oauthlib" to get the modules. In the terminal window, I can "import requests" without problems, but when I try to "import requests_oauthlib", I get the following:
>>> import requests_oauthlib Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python2.7/site-packages/requests_oauthlib/__init__.py", line 1, in <module> from .oauth1_auth import OAuth1 File "/usr/lib/python2.7/site-packages/requests_oauthlib/oauth1_auth.py", line 10, in <module> from requests.utils import to_native_string File "/usr/lib/python2.7/site-packages/requests/utils.py", line 23, in <module> from . import __version__ ImportError: cannot import name __version__
Line 23 utils.py really looks like this:
from . import __version__
I am using Python 2.7.5 on Fedora, and I am currently banging my head against this wall after several attempts to make it work, any help would be greatly appreciated ...
hyssop
source share