question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ClassNotFoundException: com.auth0.android.lock

See original GitHub issue

Description

I was working on a new release when I noticed our lock login activity no longer loaded the email/password entry fields. It is just blank with the ability to toggle between log in and sign up but no thing in the content area above the submit button. (see screenshot)

The only error message I could find is the following one.

E/Parcel: Class not found when unmarshalling: com.auth0.android.lock.internal.configuration.Options
    java.lang.ClassNotFoundException: com.auth0.android.lock.internal.configuration.Options
        at java.lang.Class.classForName(Native Method)
        at java.lang.Class.forName(Class.java:453)
        at android.os.Parcel.readParcelableCreator(Parcel.java:2827)
        at android.os.Parcel.readParcelable(Parcel.java:2781)
        at android.os.Parcel.readValue(Parcel.java:2684)
        at android.os.Parcel.readArrayMapInternal(Parcel.java:3053)
        at android.os.BaseBundle.initializeFromParcelLocked(BaseBundle.java:288)
        at android.os.BaseBundle.unparcel(BaseBundle.java:232)
        at android.os.BaseBundle.getString(BaseBundle.java:1155)
        at android.content.Intent.getStringExtra(Intent.java:8111)
        at com.android.server.am.ActivityStarter.startActivity(ActivityStarter.java:724)
        at com.android.server.am.ActivityStarter.startActivity(ActivityStarter.java:662)
        at com.android.server.am.ActivityStarter.startActivityMayWait(ActivityStarter.java:1511)
        at com.android.server.am.ActivityStarter.execute(ActivityStarter.java:603)
        at com.android.server.am.ActivityManagerService.startActivityAsUser(ActivityManagerService.java:6645)
        at com.android.server.am.ActivityManagerService.startActivityAsUser(ActivityManagerService.java:6519)
        at com.android.server.am.ActivityManagerService.startActivity(ActivityManagerService.java:6510)
        at android.app.IActivityManager$Stub.onTransact$startActivity$(IActivityManager.java:10833)
        at android.app.IActivityManager$Stub.onTransact(IActivityManager.java:111)
        at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:4126)
        at android.os.Binder.execTransact(Binder.java:739)
     Caused by: java.lang.ClassNotFoundException: com.auth0.android.lock.internal.configuration.Options
        at java.lang.Class.classForName(Native Method)
        at java.lang.BootClassLoader.findClass(ClassLoader.java:1346)
        at java.lang.BootClassLoader.loadClass(ClassLoader.java:1406)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:312)
        at java.lang.Class.classForName(Native Method) 
        at java.lang.Class.forName(Class.java:453) 
        at android.os.Parcel.readParcelableCreator(Parcel.java:2827) 
        at android.os.Parcel.readParcelable(Parcel.java:2781) 
        at android.os.Parcel.readValue(Parcel.java:2684) 
        at android.os.Parcel.readArrayMapInternal(Parcel.java:3053) 
        at android.os.BaseBundle.initializeFromParcelLocked(BaseBundle.java:288) 
        at android.os.BaseBundle.unparcel(BaseBundle.java:232) 
        at android.os.BaseBundle.getString(BaseBundle.java:1155) 
        at android.content.Intent.getStringExtra(Intent.java:8111) 
        at com.android.server.am.ActivityStarter.startActivity(ActivityStarter.java:724) 
        at com.android.server.am.ActivityStarter.startActivity(ActivityStarter.java:662) 
        at com.android.server.am.ActivityStarter.startActivityMayWait(ActivityStarter.java:1511) 
        at com.android.server.am.ActivityStarter.execute(ActivityStarter.java:603) 
        at com.android.server.am.ActivityManagerService.startActivityAsUser(ActivityManagerService.java:6645) 
        at com.android.server.am.ActivityManagerService.startActivityAsUser(ActivityManagerService.java:6519) 
        at com.android.server.am.ActivityManagerService.startActivity(ActivityManagerService.java:6510) 
        at android.app.IActivityManager$Stub.onTransact$startActivity$(IActivityManager.java:10833) 
        at android.app.IActivityManager$Stub.onTransact(IActivityManager.java:111) 
        at com.android.server.am.ActivityManagerService.onTransact(ActivityManagerService.java:4126) 
        at android.os.Binder.execTransact(Binder.java:739) 
     Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack trace available

Reproduction

I hadn’t made very many changes so I reverted them one by one. This is what caused the problem for me.

Moving from 'com.google.android.material:material:1.0.0' to 'com.google.android.material:material:1.1.0'

Reverting to the 1.0.0 version has fixed the issue for me so I am still able to release our next version but I’m not sure what that would have to do with the issue I am seeing. Progaurd doesn’t seem to be the problem because it happens in debug builds without progaurd files.

I’m creating Lock this way and it has been working for a year or so now for many releases:

private fun createLock(): Lock {
        val account = Auth0(Auth0Constants.clientId, Auth0Constants.domain)
        account.isOIDCConformant = true
        return Lock.newBuilder(account, callback)
            //Customize Lock
            .withAudience(Auth0Constants.audience)
            .withScheme(Auth0Constants.scheme)
            .withScope(Auth0Constants.scope)
            .closable(true)
            .hideMainScreenTitle(true)
            .build(context)
    }

Environment

Reproduced on Lock versions 2.14.1 and 2.17.1 min sdk version 21 target sdk version 29

Screenshot_20200217-103245_tilt dev

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
hazsetatacommented, Mar 31, 2020

I ran into the same problem today - for now I also reverted back to 1.0.0 of material.

I also found that if you disable signup (builder.allowSignUp(false)) then the login UI displays correctly even with 1.1.0 version of material.

0reactions
lbalmacedacommented, Mar 16, 2021

Closing due to inactivity

Read more comments on GitHub >

github_iconTop Results From Across the Web

Didn't find class … on path: DexPathList in release mode
ClassNotFoundException : Didn't find class "com.google.gson.JsonParser" on path: ... +' compile 'com.auth0.android:lock-facebook:2.4.
Read more >
Android Lock: does not work general login flow
Im doing everything according to Lock.Android: Get Started tutorial, its very very sad :frowning: The libraries are: auth0: 1.15.1
Read more >
Auth0.Android
Android. Auth0.Android is a client-side library you can use with your Android app to authenticate users and access Auth0 APIs.
Read more >
Lock.Android: Get Started - Auth0
Android library the minimum required Android API level is 21+ and Java version 8 or above. You will also require an Auth0 application...
Read more >
"Can't load the login box." error Auth0 Lock 2 Android
Platform: Android Product: com.auth0.android:lock:2.6.0 . (Lock widget 2.6.0) We present the Auth0 Lock 2 widget with email, facebook, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found