0

I'm trying to build an app to look at trending tweets from the bottom up building on the examples given; my steps so far:

  • Download relvent files
  • Make a new project
  • Paste in example code from here
  • Setup external library/archive things (I made this error to begin with)
  • Put my properties into a twitter4j.properties page
  • Run the program

As you can see I've not done much, and I'm hoping someone else has done the same and run in to the same problem:

This is my error/stacktrace, I've clipped the lower part off

connect timed outRelevant discussions can be found on the Internet at:
    http://www.google.co.jp/search?q=9a14e686 or
    http://www.google.co.jp/search?q=08e0e81f
TwitterException{exceptionCode=[9a14e686-08e0e81f 538e21cf-133c1788], 
statusCode=-1, retryAfter=-1, rateLimitStatus=null, featureSpecificRateLimitStatus=null,
version=2.2.6}
at twitter4j.internal.http.HttpClientImpl.request(HttpClientImpl.java:200)

The only discussion I can find is here, it's a year old and none of it seem relevant to me. But I dunno, maybe I'm wrong?

Community
  • 1
  • 1
AncientSwordRage
  • 7,086
  • 19
  • 90
  • 173

1 Answers1

1

i have also face this problem and then solve it in this way -

Add a call back url in your twitter app , might be that is wrong or still now not working or perfect, then add that url in your class as a call back url while getting authentication token from twitter, this will solve that error you now facing.

private static final String CALLBACK_URL = "http://chinu.talgol.com/";

this url is also in app's callback url.

mTwitter.getOAuthRequestToken(CALLBACK_URL);

I have solved it this way, but i am not sure this is the right, but it didn't do any harm to my app while twitting.

Chinmoy Debnath
  • 2,814
  • 16
  • 20
  • I've added it in to my main as `getOAuthRequestToken(CALLBACK_URL)` and the string elsewhere as appropriate I'm now getting a "Access token already available." error instead, did you encounter this? – AncientSwordRage Sep 12 '12 at 10:50
  • nop, i think you can do like first check if this is new user or not. If new then get authentication and store the access token in preference. If old user then use this token to twit. By storing token to preference you can know status of user and i think your current error is may be this type , where user is already signed in. – Chinmoy Debnath Sep 12 '12 at 11:01
  • I'm already storing those details in my properties file. Should everything I check my OAuth against be done programaticallly? – AncientSwordRage Sep 12 '12 at 12:37