parceler icon indicating copy to clipboard operation
parceler copied to clipboard

Class not found when unmarshalling ,Class not found exception

Open utkarshGithub opened this issue 6 years ago • 8 comments

Why my only one class is not getting unmarshalled. The error is class not found when unmarshalling: com.Inbox.InboxModel$$Parcelable while I can see com.Inbox.InboxModel$$Parcelable in generated files.

utkarshGithub avatar Jun 12 '19 08:06 utkarshGithub

I have two modules in one module I am using : implementation 'org.parceler:parceler-api:1.1.11' annotationProcessor 'org.parceler:parceler:1.1.11' and kapt 'org.parceler:parceler:1.1.11' and in other implementation 'org.parceler:parceler-api:1.1.11' annotationProcessor 'org.parceler:parceler:1.1.11'

utkarshGithub avatar Jun 12 '19 08:06 utkarshGithub

im getting this as well

04-30 21:06:55.550  9248  9277 E Parcel  : Class not found when unmarshalling: alpine.term.TrackedActivity$$Parcelable
04-30 21:06:55.550  9248  9277 E Parcel  : java.lang.ClassNotFoundException: alpine.term.TrackedActivity$$Parcelable
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.Class.classForName(Native Method)
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.Class.forName(Class.java:453)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Parcel.readParcelableCreator(Parcel.java:2811)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Parcel.readParcelable(Parcel.java:2765)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Message.readFromParcel(Message.java:622)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Message.access$000(Message.java:34)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Message$1.createFromParcel(Message.java:578)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Message$1.createFromParcel(Message.java:575)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.IMessenger$Stub.onTransact(IMessenger.java:52)
04-30 21:06:55.550  9248  9277 E Parcel  :      at android.os.Binder.execTransact(Binder.java:731)
04-30 21:06:55.550  9248  9277 E Parcel  : Caused by: java.lang.ClassNotFoundException: alpine.term.TrackedActivity$$Parcelable
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.Class.classForName(Native Method)
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.BootClassLoader.findClass(ClassLoader.java:1346)
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.BootClassLoader.loadClass(ClassLoader.java:1406)
04-30 21:06:55.550  9248  9277 E Parcel  :      at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
04-30 21:06:55.550  9248  9277 E Parcel  :      ... 10 more
04-30 21:06:55.550  9248  9277 E Parcel  : Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack trace available
04-30 21:06:55.556  9248  9277 W Binder  : Caught a RuntimeException from the binder stub implementation.
04-30 21:06:55.556  9248  9277 W Binder  : android.os.BadParcelableException: ClassNotFoundException when unmarshalling: alpine.term.TrackedActivity$$Parcelable
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Parcel.readParcelableCreator(Parcel.java:2839)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Parcel.readParcelable(Parcel.java:2765)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Message.readFromParcel(Message.java:622)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Message.access$000(Message.java:34)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Message$1.createFromParcel(Message.java:578)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Message$1.createFromParcel(Message.java:575)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.IMessenger$Stub.onTransact(IMessenger.java:52)
04-30 21:06:55.556  9248  9277 W Binder  :      at android.os.Binder.execTransact(Binder.java:731)
04-30 21:06:55.586  4453  4453 V NavigationBar: onRotationProposal proposedRotation=ROTATION_0, winRotation=ROTATION_0, isValid=true, mNavBarWindowState=WINDOW_STATE_SHOWING, rotateSuggestionsDisabled=false, isRotateButtonVisible=false
04-30 21:06:55.596  4002  5624 W SurfaceFlinger: Attempting to set client state on removed layer: Splash Screen alpine.term#0
04-30 21:06:55.596  4002  5624 W SurfaceFlinger: Attempting to destroy on removed layer: Splash Screen alpine.term#0
04-30 21:06:55.707  4002  5624 E BufferQueueProducer: [com.android.launcher3/com.android.launcher3.lineage.LineageLauncher#0] disconnect: not connected (req=1)
04-30 21:06:55.707  5089  5737 W libEGL  : EGLNativeWindowType 0x79883f2010 disconnect failed
04-30 21:06:55.723  4002  5624 E BufferQueueProducer: [com.android.launcher3/com.android.launcher3.lineage.LineageLauncher#1] disconnect: not connected (req=1)
04-30 21:06:55.723  7219  7458 W libEGL  : EGLNativeWindowType 0x799a977010 disconnect failed
04-30 21:06:55.758  5089  5366 I WorkerManager: Releasing worker: [searchboxroot]/[24]/[com.google.android.apps.gsa.staticplugins.searchboxroot.x]
04-30 21:06:55.758  5089  5366 I chatty  : uid=10188(com.google.android.googlequicksearchbox) EventBus0 identical 2 lines
04-30 21:06:55.758  5089  5366 I WorkerManager: Releasing worker: [searchboxroot]/[24]/[com.google.android.apps.gsa.staticplugins.searchboxroot.x]
04-30 21:06:55.759  5089  5366 I WorkerManager: Releasing worker: [actions]/[1]/[com.google.android.apps.gsa.staticplugins.actions.p]
04-30 21:06:55.760  5089  5366 I chatty  : uid=10188(com.google.android.googlequicksearchbox) EventBus0 identical 2 lines
04-30 21:06:55.761  5089  5366 I WorkerManager: Releasing worker: [actions]/[1]/[com.google.android.apps.gsa.staticplugins.actions.p]
04-30 21:06:55.761  5089  8868 I PBSessionCacheImpl: Deleted sessionId[22383246916794181] from persistence.
04-30```

mgood7123 avatar Apr 30 '20 11:04 mgood7123

Are you using proguard?

johncarl81 avatar May 02 '20 23:05 johncarl81

Yes

On Sun., 3 May 2020, 9:12 am John Ericksen, [email protected] wrote:

Are you using proguard?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/johncarl81/parceler/issues/373#issuecomment-623027627, or unsubscribe https://github.com/notifications/unsubscribe-auth/AGLITH3IPF6GLZTIJRWAUU3RPSSFJANCNFSM4HXGVSCA .

mgood7123 avatar May 02 '20 23:05 mgood7123

Can you share your configuration? Here's the config that generally works: http://parceler.org/#configuring_proguard

johncarl81 avatar May 03 '20 01:05 johncarl81

@johncarl81 any solution? i removed proguard but still getting the issue

tronku avatar Feb 17 '23 13:02 tronku

It's likely because of one of two things: Not adding or configuring the annotation processor properly, or proguard is removing the generated Parcelable classes.

johncarl81 avatar Feb 17 '23 17:02 johncarl81

alright

mgood7123 avatar Feb 18 '23 09:02 mgood7123