Android Firebase DynamiteModule: Failed to load module descriptor

Since upgrading to the latest version of Firebase (9.0.0), I canโ€™t get rid of the following two errors when authenticating a user through signInWithEmailAndPassword() . Does anyone know what is going on?

  05-19 18:09:49.245 23550-23589/[PACKAGE] E/DynamiteModule: Failed to load module descriptor class: Didn't find class "com.google.android.gms.dynamite.descriptors.com.google.firebase.auth.ModuleDescriptor" on path: DexPathList[[zip file "/data/app/[PACKAGE]-3/base.apk"],nativeLibraryDirectories= [/data/app/[PACKAGE]-3/lib/x86, /vendor/lib, /system/lib]] 

and

  05-19 18:09:49.252 23550-23550/[PACKAGE] E/FirebaseApp: Firebase API initialization failure.java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at com.google.firebase.FirebaseApp.zza(Unknown Source) at com.google.firebase.FirebaseApp.initializeApp(Unknown Source) at com.google.firebase.FirebaseApp.initializeApp(Unknown Source) at com.google.firebase.FirebaseApp.zzbu(Unknown Source) at com.google.firebase.provider.FirebaseInitProvider.onCreate(Unknown Source) at android.content.ContentProvider.attachInfo(ContentProvider.java:1748) at android.content.ContentProvider.attachInfo(ContentProvider.java:1723) at com.google.firebase.provider.FirebaseInitProvider.attachInfo(Unknown Source) (...) Caused by: java.lang.IncompatibleClassChangeError: The method 'java.io.File android.support.v4.content.ContextCompat.getNoBackupFilesDir(android.content.Context)' was expected to be of type virtual but instead was found to be of type direct (declaration of 'com.google.firebase.iid.zzg' appears in /data/data/[PACKAGE]/files/instant-run/dex/slice-com.google.firebase-firebase-iid-9.0.0_95503dc60ed409569d1585da411de93e6c633bf7-classes.dex) at com.google.firebase.iid.zzg.zzeC(Unknown Source) at com.google.firebase.iid.zzg.<init>(Unknown Source) at com.google.firebase.iid.zzg.<init>(Unknown Source) at com.google.firebase.iid.zzd.zzb(Unknown Source) at com.google.firebase.iid.FirebaseInstanceId.getInstance(Unknown Source) at java.lang.reflect.Method.invoke(Native Method) at com.google.firebase.FirebaseApp.zza(Unknown Source) at com.google.firebase.FirebaseApp.initializeApp(Unknown Source) at com.google.firebase.FirebaseApp.initializeApp(Unknown Source) at com.google.firebase.FirebaseApp.zzbu(Unknown Source) at com.google.firebase.provider.FirebaseInitProvider.onCreate(Unknown Source) at android.content.ContentProvider.attachInfo(ContentProvider.java:1748) at android.content.ContentProvider.attachInfo(ContentProvider.java:1723) at com.google.firebase.provider.FirebaseInitProvider.attachInfo(Unknown Source) (...) 
+67
android firebase firebase-authentication
May 19 '16 at 16:18
source share
13 answers

Can you check your version of Google Play Services?

From the Firebase oficial website :

Background

  • Android device with Google Play Services 9.0.0 or later
  • Google Play Services SDK from Android SDK Manager
  • Android Studio 1.5 or higher
  • Android Studio project and its package name.
+11
May 19 '16 at 16:23
source share

I had the same problem and found the error I made in the Firebase console.

One of the reasons for this problem may be your Firebase login method> control panel .

I just turned it on and it started working.

+26
May 21 '16 at 7:06 a.m.
source share

It is very sad that Firebase initialization errors are so complex that developers must guess what went wrong. In my case, I only imported:

 compile 'com.google.firebase:firebase-auth:10.2.0' 

and forgot to import the kernel as well:

 compile 'com.google.firebase:firebase-core:10.2.0' 

Maybe this will help someone, good luck!

+3
Feb 21 '17 at 6:36
source share

I found a problem. The problem was the first premise that Guilherme spoke about, but not the bold part. Although your dependencies should also explicitly indicate 9. + parts of the game services , the devices themselves must also have 9. + installed . Debugging on my phone works fine, and updating the image of my emulator also solves the problem.

+1
May 19 '16 at 18:58
source share

Disabling Instant Run worked for me. Sounds funny, I know. I tried to clean the project. I tried uninstalling / reinstalling the application. What, in the end, did the trick was disabling Instant Run. Sigh

+1
Nov 19 '16 at 1:36
source share

I logged out and then logged in and solved this problem for me.

Probably due to some kind of synchronization, the FB stuff is not implemented.

If this problem consists, I will try to intercept it. But, rather, this is a bug in the Firebase system. And this is a mistake caused by more than one use case, which is another problem in itself.

+1
Feb 07 '17 at 11:29 on
source share

This answer on another question made my application authenticate

Alfonso Gomez Jordana Manas

Hi Pierre

You must manually reinstall the existing Google OAuth 2.0 client identifiers in the Firebase console before using them with the new Auth APIs.

To do this, follow these steps:

  • Go to the Credentials section of the Google APIs console.
  • Select the project in the upper right corner in which you previously set up Google login.
  • Go to the OAuth 2.0 Client Identifiers section. If you are using a Google account in Android or iOS applications: Pay attention to the client identifier string corresponding to all entries registered for your applications.
  • Enter these client identifiers in your Firebase project configuration:
  • Go to the Firebase console at https://console.firebase.google.com
  • Open the Auth section

    In the "Login" section, open the Google configuration and add all your customer IDs to the white list of customer IDs from external projects. If you are using a Google account in a web application: Click to open the web client ID and take note of both the client ID and the secret. Enter this client ID in the Firebase project configuration: Go to the Firebase console at https://console.firebase.google.com Open the Auth section In the "Login" section, open the Google configuration and add the values โ€‹โ€‹in the "Web SDK configuration" section "

Let me know if this solves your problem.

0
May 20 '16 at 11:54
source share

You can check when adding google login option before using

 GoogleSignInOptions gso = new GoogleSignInOptions .Builder(GoogleSignInOptions.DEFAULT_SIGN_IN) .requestEmail() .build(); 

add one line as shown in the following code

 GoogleSignInOptions gso = new GoogleSignInOptions .Builder(GoogleSignInOptions.DEFAULT_SIGN_IN) .requestIdToken(getString(R.string.default_web_client_id)) .requestEmail() .build(); 

after adding this if you get an error like

 An internal error has occured. [ Invalid Idp Response: id_token audience mismatch. ] 

then Click here to get a solution, this works for me.

0
May 23 '16 at 6:43 a.m.
source share

If you just want to use Firebase authentication, and you got here because of an error:

Did not find class "Com.google.android.gms.dynamite.descriptors.com.google.firebase.auth.ModuleDescriptor"

Go to https://console.firebase.google.com/ project / [your project] / authentication / providers and enable the authentication providers that you support.

0
May 23 '16 at 16:25
source share

I had a similar problem with user registration, but finally I found a working solution.

Uninstall HAXM and reinstall it. solves my problem and successfully registers the user for firebase auth :)

0
May 24 '16 at 19:35
source share

if you are doing everything but not trying to update your ARM EABI.

Google API ARM EABI v7a System Image

If your emulator does not have new goggle updates, you will always get an auth error.

Do everything suggested in this post, and then refresh the ARM EABI image. This solved my problem.

0
Aug 21 '16 at 16:40
source share

This can happen if you do not have SHA1 fingerprints registered in Firebase and the Google API. In both of them, you need to register two fingerprints: from the debug storage and from the production key store (created when you created the apk project for the first time when you enter some password keys in Android Studio).

Here is how to get SHA1 from there.

or run this command in the C:\Users\<user name>\.android directory.

 keytool -list -v -keystore debug.keystore 
0
Sep 07 '17 at 22:08
source share

Exchange of experience: I encountered the same problem, I searched everywhere on Google, but could not find the exact answer, even if I did everything as described in the Google Android documentation. Unexpectedly, a day later my application was working fine, and at that very moment I received an email from google stating that "Google API Explorer is connected to your Google account." And it seems to me that Google takes time to give us access, just wait for this letter, maybe this problem is not related to bad code.

0
Oct 08 '17 at 2:55 on
source share



All Articles