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.

Compatability issue (crash) with SDK 10.2.0

See original GitHub issue
  • Android device: Pixel XL
  • Android OS version: 7.1.1
  • Google Play Services version: 10.2.98
  • Firebase/Play Services SDK version: 10.2.0
  • FirebaseUI version: 1.1.1

FirebaseUI 1.1.1 causes a crash with the new Firebase SDK 10.2.0:

E/AndroidRuntime: FATAL EXCEPTION: main Process: com.google.firebase.udacity.friendlychat, PID: 17822 java.lang.NoSuchMethodError: No virtual method zzqJ()Ljava/util/ArrayList; in class Lcom/google/android/gms/auth/api/signin/GoogleSignInOptions; or its super classes (declaration of ‘com.google.android.gms.auth.api.signin.GoogleSignInOptions’ appears in /data/app/com.google.firebase.udacity.friendlychat-2/base.apk:classes13.dex) at com.google.android.gms.auth.api.Auth$3.zza(Unknown Source) at com.google.android.gms.auth.api.Auth$3.zzp(Unknown Source) at com.google.android.gms.common.api.GoogleApiClient$Builder.addApi(Unknown Source) at com.firebase.ui.auth.provider.GoogleProvider.(GoogleProvider.java:84) at com.firebase.ui.auth.provider.GoogleProvider.(GoogleProvider.java:54) at com.firebase.ui.auth.ui.idp.AuthMethodPickerActivity.populateIdpList(AuthMethodPickerActivity.java:96) at com.firebase.ui.auth.ui.idp.AuthMethodPickerActivity.onCreate(AuthMethodPickerActivity.java:80) at android.app.Activity.performCreate(Activity.java:6679) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1118) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2618) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2726) at android.app.ActivityThread.-wrap12(ActivityThread.java) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1477) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:154) at android.app.ActivityThread.main(ActivityThread.java:6119) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)

Downgrading to Firebase SDK 10.0.1 (the most recent listed version in the FirebaseUI compatibility table) resolves the problem. I am aware that 10.2.0 isn’t listed in the table (so it should come as no surprise it may not work), but this is the recommended version from the Firebase Android SDK page, so a warning at least for new users in the Readme might be useful until a patch is ready.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
SUPERCILEXcommented, Feb 20, 2017

@redbassett Please add the dependencies I asked you to try:

compile "com.google.firebase:firebase-core:$playServicesVersion"
compile "com.google.firebase:firebase-auth:$playServicesVersion"
compile "com.google.android.gms:play-services-auth:$playServicesVersion"
1reaction
redbassettcommented, Feb 19, 2017

Working dependencies:

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:design:24.2.0'
    compile 'com.android.support:appcompat-v7:24.2.0'
    compile 'com.github.bumptech.glide:glide:3.6.1'
    compile 'com.android.support:multidex:1.0.1'

    compile 'com.google.firebase:firebase-database:10.0.1'
    compile 'com.google.firebase:firebase-auth:10.0.1'
    compile 'com.google.firebase:firebase-storage:10.0.1'
    compile 'com.google.firebase:firebase-messaging:10.0.1'
    compile 'com.google.firebase:firebase-config:10.0.1'
    compile 'com.firebaseui:firebase-ui-auth:1.1.1'
}

apply plugin: 'com.google.gms.google-services'

Non-working dependencies:

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:design:24.2.0'
    compile 'com.android.support:appcompat-v7:24.2.0'
    compile 'com.github.bumptech.glide:glide:3.6.1'
    compile 'com.android.support:multidex:1.0.1'

    compile 'com.google.firebase:firebase-database:10.2.0'
    compile 'com.google.firebase:firebase-auth:10.2.0'
    compile 'com.google.firebase:firebase-storage:10.2.0'
    compile 'com.google.firebase:firebase-messaging:10.2.0'
    compile 'com.google.firebase:firebase-config:10.2.0'
    compile 'com.firebaseui:firebase-ui-auth:1.1.1'
}

apply plugin: 'com.google.gms.google-services'

This is the offending line of Java:

@Override
protected void onResume() {
    super.onResume();
    mFirebaseAuth.addAuthStateListener(mAuthStateListener);
}

The above method works fine with the working dependencies, but crashes with the non-working ones.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Firebase Android SDK Release Notes - Google
Fixed an issue preventing native crashes from being reported for Android API 29+. ... Internal changes to maintain compatibility with other Firebase SDKs....
Read more >
Xcode 10.2 Release Notes | Apple Developer Documentation
Resolved an issue that affected app compatibility with iOS 9.0, 9.1, and 9.2 when distributing an app for local or enterprise distribution.
Read more >
Firebase database dependency crashes app - Stack Overflow
This problem is caused by use of inconsistent Firebase library versions. Update your build dependencies to consistently use version 9.4.0.
Read more >
Release Notes - Play services - Google Developers
Firebase Crashlytics. For more information, see the Firebase Android SDK Release Notes. The latest update to the TensorFlow Lite for Play services libraries ......
Read more >
Mobile App Messaging SDK for iOS — Regular Releases
getBundle() due LPLogger; Fixed issue when SDK will crash when checking ... The iOS Mobile Messaging SDK version 3.8.1 is compatible with Xcode...
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