简体   繁体   中英

Fatal Exception: java.lang.IncompatibleClassChangeError: Couldn't find com.google.a.a.c.a

I am getting this Exception repeatedly in CrashListics from Samsung devices with operating system 5.0.1 i searched in SO a lot and find that it is a bug in samsung devices but unable to find any solution. can anyone suggest me how to handle this exception (any solution or any trick) ?

Fatal Exception: java.lang.IncompatibleClassChangeError: Couldn't find com.google.aaca at libcore.reflect.AnnotationAccess.toAnnotationInstance(AnnotationAccess.java:659) at libcore.reflect.AnnotationAccess.toAnnotationInstance(AnnotationAccess.java:641) at libcore.reflect.AnnotationAccess.getDeclaredAnnotation(AnnotationAccess.java:170) at java.lang.reflect.Field.getAnnotation(Field.java:242) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.excludeField(Unknown Source) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.excludeField(Unknown Source) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.excludeField(Unknown Source) at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.excludeField(Unknown Source) at com.google.gson.Gson.doubleAdapter(Unknown Source) at com.google.gson.Gson.doubleAdapter(Unknown Source) at com.google.gson.Gson.doubleAdapter(Unknown Source) at com.google.gson.Gson.doubleAdapter(Unknown Source) at com.google.gson.Gson .doubleAdapter(Unknown Source) at com.app.Data.Sessions.LoginSession.createLoginSession(Unknown Source) at com.app.Data.UserInformation.getInfo(Unknown Source) at com.app.Main.LocationUpdateService.locationUpdate(Unknown Source) at com.app.Main.LocationUpdateService.locationUpdate(Unknown Source) at com.app.Main.LocationUpdateService$1.onLocationChanged(Unknown Source) at android.location.LocationManager$ListenerTransport._handleMessage(LocationManager.java:281) at android.location.LocationManager$ListenerTransport.access$000(LocationManager.java:210) at android.location.LocationManager$ListenerTransport$1.handleMessage(LocationManager.java:226) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:145) at android.app.ActivityThread.main(ActivityThread.java:5942) at java.lang.reflect.Method.invoke(Method.java) at java.lang.reflect.Method.invoke(Method.java:372) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1399) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1194)

In createLoginSession what i am doing is :

public void createLoginSession(UserData userData) {
    Gson gson = new Gson();
    String info = gson.toJson(userData);
    editor.putString(INFO, info);
    editor.commit();
}

YOu need to keep your model UserData , don't obfuscate that. Like this:

-keep class yourpackage.model.** { *; }

and keep your gson

-keep class com.google.gson.stream.** { *; }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM