-
-
Notifications
You must be signed in to change notification settings - Fork 4.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AttributeError: 'module' object has no attribute 'OAuthHandler' #490
Comments
Try: from tweepy.auth import OAuthHandler |
Unfortunately, it doesn't change anything. More ideas? |
I mean: from tweepy.auth import OAuthHandler (then...) auth = OAuthHandler(consumer_key, consumer_secret) |
without the tweepy before OAuthHandler it seems to work, but why is this so? |
I assume I'll get the error wherever I put tweepy before a function? |
A clean uninstall with pip and reinstall helped. So far, I'm not getting this error any longer. Thank you! |
I fixed this in d9d5a86. Sorry for the problems! |
Thanks for helping out and it's good to know that there was an error in the code. All I complained about before is resolved now, but when I try a simple request such as:
I get the following error:
My feeling is that I'm just too dumb to authenticate properly. |
Oh, sorry. I've considered removing that unauthenticated instance. Basiclly, all Twitter API endpoints require authentication (they didn't use to, years, ago, thus You have to create an instance of tweepy.API, by creating an instance of OAuthHandler. Here's an example, using the consumer and access tokens/secrets given to you from the app you create with Twitter on their dev site. |
I did this and it works fine, but when I'll try to go beyond the example with the above code I'll get the same errors again. |
OK. I continued using tweepy before a command such as get_user. On my behalf, I'm new to Python and programming in general. Thank you for all your patience. Instead of:
This is working:
|
Right, sorry, I should have mentioned that. You need to use the authenticated API instance you created for all calls you make. |
Dear Tweepy Team, |
Dear Tweepy Team, I keep running into this error and I'm really frustrated. Have I installed it correctly? Or where could this error come from? I have no clue: auth.set_access_token(config.access_token, config.access_secret) Any Advice is Appreciated |
its an O. |
Note, as previously stated, this issue was fixed with d9d5a86 as part of v3.0.0. @varunjain97 That is not related to this issue and doesn't even seem to be related to this library. @MVL10 This is not related to this issue and is not an issue with the library. |
Dear Tweepy Team,
I'm keep running into this error and I'm really frustrated. Have I installed it correctly? Or where could this error come from? I have no clue:
Any advice is appreciated!
Kind regards
The text was updated successfully, but these errors were encountered: