My app has been working well at Support Libraries 23.1.1. However, after upgrading to Support Libraries 23.2.0, it starts to crash. The crash happens when I navigate from an activity back to the main activity (for example, I open the about activity from main activity's actionbar menu, then press back button to go back to main activity, then it crashes).
The crash log is here:
FATAL EXCEPTION: main Process: com.myapp.blah.blah, PID: 22124 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.myapp.blah.blah/com.myapp.blah.blah.ui.MainActivity}: java.lang.RuntimeException: Parcel android.os.Parcel@41d10870: Unmarshalling unknown type code 6881391 at offset 4752 at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2429) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493) at android.app.ActivityThread.access$800(ActivityThread.java:166) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:136) at android.app.ActivityThread.main(ActivityThread.java:5584) at java.lang.reflect.Method.invokeNative(Native Method) at java.lang.reflect.Method.invoke(Method.java:515) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084) at dalvik.system.NativeStart.main(Native Method) Caused by: java.lang.RuntimeException: Parcel android.os.Parcel@41d10870: Unmarshalling unknown type code 6881391 at offset 4752 at android.os.Parcel.readValue(Parcel.java:2087) at android.os.Parcel.readArrayMapInternal(Parcel.java:2321) at android.os.Bundle.unparcel(Bundle.java:249) at android.os.Bundle.getSparseParcelableArray(Bundle.java:1273) at com.android.internal.policy.impl.PhoneWindow.restoreHierarchyState(PhoneWindow.java:1884) at android.app.Activity.onRestoreInstanceState(Activity.java:989) at android.app.Activity.performRestoreInstanceState(Activity.java:961) at android.app.Instrumentation.callActivityOnRestoreInstanceState(Instrumentation.java:1145) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2407) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2493)? at android.app.ActivityThread.access$800(ActivityThread.java:166)? at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1283)? at android.os.Handler.dispatchMessage(Handler.java:102)? at android.os.Looper.loop(Looper.java:136)? at android.app.ActivityThread.main(ActivityThread.java:5584)? at java.lang.reflect.Method.invokeNative(Native Method)? at java.lang.reflect.Method.invoke(Method.java:515)? at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1268)? at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1084)? at dalvik.system.NativeStart.main(Native Method)?
The crash only happens if I set the developer debug option "do not keep activities" on. The crash does not happen if this option is off.
The crashes happens in debug mode where no Proguard is used.
I do not pass any parcels/bundles between the activities, and do not use startActivityForResult().
Crash happens on both pre and post Lollipop devices.
I found two similar posts here and here which might (or might not) be related.