0

I searched very much but I did not see the real solution. Somebody says use ex facebook sdk , is it the real solution?(I use facebook 3.6 but somebody says on stackoverflow use 3.2) I use proguard,

com.facebook.aq: com.facebook.c.f got an unexpected method signature: public abstract java.lang.Object com.facebook.c.c.e()
at com.facebook.c.h.a(Unknown Source)
at com.facebook.c.f.invoke(Unknown Source)
at $Proxy0.e(Native Method)
at com.facebook.b.al.a(Unknown Source)
at com.facebook.b.al.a(Unknown Source)
at com.facebook.f.run(Unknown Source)
at java.util.Timer$TimerImpl.run(Timer.java:284)
user3086226
  • 93
  • 1
  • 7
  • 18
  • What is _ex facebook sdk_? – M D Mar 12 '14 at 06:09
  • I use facebook 3.6 but somebody says on stackoverflow use 3.2 – user3086226 Mar 12 '14 at 06:10
  • I think you go wrong way. always used Latest SDK and your logcat said that your SDK not contain some classes that you import into your java class – M D Mar 12 '14 at 06:17
  • Simple solution already provided in older post. [Click here][1]. [1]: http://stackoverflow.com/questions/15760581/android-proguard-settings-for-facebook – Mitech Mar 29 '15 at 17:52

2 Answers2

0

You should use the latest facebook sdk and you should login with using app_secret like this :

  String access_token = sharedPrefs.getString("access_token", app_secret );
        Long expires = sharedPrefs.getLong("access_expires", -1);
    mFacebook.setAccessToken(access_token);
                mFacebook.setAccessExpires(expires);

(I think this solves your problem bacause you have a problem just the first login )

CompEng
  • 7,161
  • 16
  • 68
  • 122
0

There are some settings that you need to set for proguard.

The number of posts can explain the right way.

Check them out.

Some are listed below:-

1) Using Signature - Error-on-using-proguard-with-android-facebook-sdk-3-0.

So you use -

-keepattributes Signature

2) Android-facebook-connect-not-working-in-release-build.-

So, issue can be with your proguard configuration settings:

  • proguard.cfg (ERROR)

-keep class com.facebook.android.*

-keepclassmembers public class com.facebook.android.Facebook { 

    public static final *; 
}
  • proguard.cfg (WITHOUT ERROR)

-keep class com.facebook.android.*

-keep class android.webkit.WebViewClient

-keep class * extends android.webkit.WebViewClient

-keepclassmembers class * extends android.webkit.WebViewClient { 
    <methods>; 
}

3) Android ProGuard settings for Facebook

Community
  • 1
  • 1
sjain
  • 23,126
  • 28
  • 107
  • 185