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
Twitter Stream API + OAuth not working #133
Comments
try doing a twitter_client.account.verify_credentials() And see if you oauth keys are still available. |
the
again I successfully read the home timeline and sent a direct message, isn't that a sign of the validity of the OAuth keys? |
are you using the verify method on api.twitter.com or stream.twitter.com, you should change the domain to api.twitter.com when testing the verify method. |
Yes that is true, if you have sent tweets then your oauth is working. That error is comming straight from twitter though so it seems like a temporary issue on their end. |
Point is that if I use the normal |
Hi, Did you recently upgrade to PTT 1.9.2? The default API version for the streaming class changed to '1.1'. Is it possible that the command you are running is no longer available in the 1.1 API? You can pass In API 1.1 I don't think there is a home timeline, in fact. The correct call is now:
|
Hi, https://dev.twitter.com/docs/api/1.1/get/statuses/sample This is the code that gives the error
|
Okay, thanks for the info. I just tested this exact code and it worked for me. I was able to iterate tweets from the sample stream with PTT 1.9.2, Python 2.7. Are the consumer token and secrets the same ones you authorized with originally? Even if so, maybe try doing the If you are still having trouble, please let me know what OS and Python version you are using. |
This is strange... I also tried the |
Wait wait... note the difference in the domain. I'm using |
I'm not sure to understand... or I may have made some confusion I tried the following just now
and I have the error.
and it works. changing to
|
It seems your there is something wrong with your oauth credentials. Oauth Using: twitter 1.9.2 |
It seems that my OAuth credentials are working ( @pykler I mentioned it in my original post up here ):
twitter = Twitter(auth=oauth) |
Is there a way to have print out the actual request the code is making? Thanks |
It seems I'm dwelling in the merciless pit of
Thank you! |
Thanks! I was having the same issue but now I have a healthy stream again! Is there a wiki for this code? I would love to contribute. Thanks again |
What and how please? |
Here it is guys!
appears, the answer (in 90% of the cases) is:
Yes, your system has lost a minute too much |
I've used the code some months ago, with the streaming API and the OAuth method and it worked.
Today I tried again and I'm getting a
passing through
and originating in
The same OAuth works fine with other methods: I tried both
statuses.home_timeline()
and
direct_messages.new()
The text was updated successfully, but these errors were encountered: