Got com.twitter.sdk.android.core.TwitterAuthException: Failed to get request token

android

#1

Hi,

I used Android.mk to build the apk about log in twitter.
But I always got the fail when click log in button.

07-28 11:33:29.779 E/Twitter ( 5196): Authorization completed with an error
07-28 11:33:29.779 E/Twitter ( 5196): com.twitter.sdk.android.core.TwitterAuthException: Failed to get request token
07-28 11:33:29.779 E/Twitter ( 5196): at com.twitter.sdk.android.core.identity.OAuthController$1.failure(OAuthController.java:95)
07-28 11:33:29.779 E/Twitter ( 5196): at com.twitter.sdk.android.core.internal.oauth.OAuth1aService$1.failure(OAuth1aService.java:213)
07-28 11:33:29.779 E/Twitter ( 5196): at com.twitter.sdk.android.core.Callback.failure(Callback.java:45)
07-28 11:33:29.779 E/Twitter ( 5196): at retrofit.CallbackRunnable$2.run(CallbackRunnable.java:53)
07-28 11:33:29.779 E/Twitter ( 5196): at android.os.Handler.handleCallback(Handler.java:739)
07-28 11:33:29.779 E/Twitter ( 5196): at android.os.Handler.dispatchMessage(Handler.java:95)
07-28 11:33:29.779 E/Twitter ( 5196): at android.os.Looper.loop(Looper.java:152)
07-28 11:33:29.779 E/Twitter ( 5196): at android.app.ActivityThread.main(ActivityThread.java:5505)
07-28 11:33:29.779 E/Twitter ( 5196): at java.lang.reflect.Method.invoke(Native Method)
07-28 11:33:29.779 E/Twitter ( 5196): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
07-28 11:33:29.779 E/Twitter ( 5196): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

It could work on Android Studio for same key and secret.
But I need use Android.mk to build the apk.
Could anyone help?
Many thanks.


#2

Hey @hnfish,

Unfortunately Make isn’t a officially supported build tool for Fabric. I’m surprised that how you’re building is causing this issue, but it sounds like something may be stripping out your key and secret preventing the request from working.

-Mike