我收到以下错误。有什么帮助吗?
09-25 20:44:58.934: WARN/System.err(3741): oauth.signpost.exception.OAuthExpectationFailedException: Request token or token secret not set in server reply. The service provider you use is probably buggy.
09-25 20:44:58.934: WARN/System.err(3741): at oauth.signpost.AbstractOAuthProvider.retrieveToken(AbstractOAuthProvider.java:202)
09-25 20:44:58.934: WARN/System.err(3741): at oauth.signpost.AbstractOAuthProvider.retrieveAccessToken(AbstractOAuthProvider.java:97)
09-25 20:44:58.934: WARN/System.err(3741): at corp.encameo.app.TwitterApp$3.run(TwitterApp.java:145)
09-25 20:44:58.981: ERROR/TWITTER(3741): Error getting access token
在TwitterApp.java的第145行
new Thread() {
@Override
public void run() {
int what = 1;
try {
(line 145) mHttpOauthprovider.retrieveAccessToken(mHttpOauthConsumer,
verifier);
mAccessToken = new AccessToken(
mHttpOauthConsumer.getToken(),
mHttpOauthConsumer.getTokenSecret());
configureToken();
User user = mTwitter.verifyCredentials();
mSession.storeAccessToken(mAccessToken, user.getName());
what = 0;
} catch (Exception e) {
e.printStackTrace();
}
mHandler.sendMessage(mHandler.obtainMessage(what, 2, 0));
}
}.start();
使用以下库:
signpost-commonshttp4-1.2.1.1.jar
,
signpost-core-1.2.1.1.jar
,
signpost-jetty6-1.2.1.1.jar
,
twitter4j-core-2.1.6.jar
。