You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Issues filed here should be about bugs in the code in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:
For general technical questions, post a question on StackOverflow
with the firebase tag.
For general Firebase discussion, use the firebase-talk
google group.
For help troubleshooting your application that does not fall under one
of the above categories, reach out to the personalized Firebase support channel.
[REQUIRED] Step 2: Describe your environment
Android Studio version: Android Studio Koala Feature Drop | 2024.1.2 Patch 1
Firebase Component: Auth
Component version: 23.0.0 (BOM 33.4.0)
[REQUIRED] Step 3: Describe the problem
With Firebase Auth 23.0.0 and minifyEnabled true, after signing in to Firebase Auth, quitting and relaunching the app should show a valid currentUser. Instead, instantiation of Firebase Auth fails with a JSON parsing error:
JSONArray[0] not a string.
s9.b: JSONArray[0] not a string.
at s9.a.e(Unknown Source:21)
at T6.x.a(Unknown Source:148)
at com.google.firebase.auth.FirebaseAuth.<init>(Unknown Source:213)
at com.google.firebase.auth.FirebaseAuthRegistrar.lambda$getComponents$0(Unknown Source:58)
at S6.O.b(Unknown Source:11)
at O6.d.get(Unknown Source:167)
at U6.p.get(Unknown Source:13)
at U6.c.f(Unknown Source:8)
at U6.c.a(Unknown Source:4)
at O6.h.b(Unknown Source:5)
at com.google.firebase.auth.FirebaseAuth.getInstance(SourceFile:2)
at G5.f.i0(Unknown Source:0)
at N7.g.<clinit>(Unknown Source:47)
at com.onme.giftcards.MainActivity.onCreate(Unknown Source:3)
at android.app.Activity.performCreate(Activity.java:8975)
at android.app.Activity.performCreate(Activity.java:8944)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1456)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:4146)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4322)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:139)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:96)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2685)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:230)
at android.os.Looper.loop(Looper.java:319)
at android.app.ActivityThread.main(ActivityThread.java:8919)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:578)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1103)
This frustratingly only occurs when uploaded to the Play Store—I'm unable to test locally as Firebase Auth expects a proper Play Store-signed app when in release mode.
Turning off minifyEnabled resolves this problem.
Steps to reproduce:
Turn on minifyEnabled.
Build app in release mode
Upload to Google Play
Download the uploaded app
Sign in to the app
Restart the app
Observe error and that the user is not authenticated.
Relevant Code:
Simply adding a Firebase.auth.currentUser in onCreate will reproduce this issue.
I tried adding these Proguard rules to no avail.
-keep class com.google.firebase.** { *; }
-keep class com.google.android.gms.** { *; }
-keepclasseswithmembers class com.google.firebase.FirebaseException { *; }
-keepclasseswithmembers class com.google.firebase.auth.FirebaseAuthException { *; }
-keepnames class com.google.firebase.auth.** { *; }
-keepattributes Signature
-dontwarn com.google.firebase.**
The text was updated successfully, but these errors were encountered:
Hi @dantheli, thank you for reaching out. Can you the play-services-auth version you're using? Does the issue occur on certain devices and/or android versions?
Sorry, I was meant to ask for Android Gradle plugin version. The play-service-auth dependency is required for Firebase Auth Google provider and Email linking. If you're not using them, you don't need to add the dependency.
By any chance, can you share the gradle files you're using?
[READ] Step 1: Are you in the right place?
Issues filed here should be about bugs in the code in this repository.
If you have a general question, need help debugging, or fall into some
other category use one of these other channels:
with the firebase tag.
google group.
of the above categories, reach out to the personalized
Firebase support channel.
[REQUIRED] Step 2: Describe your environment
[REQUIRED] Step 3: Describe the problem
With Firebase Auth 23.0.0 and
minifyEnabled
true, after signing in to Firebase Auth, quitting and relaunching the app should show a validcurrentUser
. Instead, instantiation of Firebase Auth fails with a JSON parsing error:This frustratingly only occurs when uploaded to the Play Store—I'm unable to test locally as Firebase Auth expects a proper Play Store-signed app when in release mode.
Turning off
minifyEnabled
resolves this problem.Steps to reproduce:
minifyEnabled
.Relevant Code:
Simply adding a
Firebase.auth.currentUser
in onCreate will reproduce this issue.I tried adding these Proguard rules to no avail.
The text was updated successfully, but these errors were encountered: