-
Notifications
You must be signed in to change notification settings - Fork 3.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🐛 [firebase_auth] NSInvalidArgumentException - One of IDToken, accessToken, pendingToken, or requestURI must be supplied. #10636
Comments
Hi @Tom3652, can you share the crash log in properly formatted text? I think this might not be an issue with firebase_crashlytics but rather |
hi @danagbemava-nc thanks for the quick reply. I am aware of this issue with This is a crash here and the stack trace doesn't mention The relevant block for me is when
Thanks for your understanding |
Hi @Tom3652, sorry, I somehow missed that part in the initial report. I believe the issue is expected because the app terminates before the message can be sent. I believe the actual issue is the Is your google sign in feature linked through Also, can you deobfuscate the crash logs so we can see what the missing sections are? https://firebase.google.com/docs/crashlytics/get-deobfuscated-reports?platform=flutter PS: that error can cause an app termination. See #9615 |
No problem !
it is linked but i am passing the I am simply using :
I have already done these steps before releasing my app, it seems it's not working... |
Thanks for the update. Have you tried using the ios specific settings to see if it helps? You can find that here https://firebase.google.com/docs/crashlytics/get-deobfuscated-reports?platform=ios |
Yes i have done it even if the dashboard doesn't tell me there are missing DSYM files. What else can i do if there is anything ? |
I'm not too sure. Labeling for further insight from the team since this is a production crash with no steps to reproduce. /cc @Lyokone |
I have reached out firebase support to know more about de-obfuscation, will update here if i manage to get the readable trace. |
@danagbemava-nc Firebase support answered :
But my app was released with 10.6.0 using the latest |
The latest version of firebase_core 2.9.0 contains 10.7.0. Let us know if it helps. |
Hi @Lyokone, thanks you are right it actually contains, my I will be releasing a new version today with |
Hey @Lyokone i have got the crash again and the deobfuscation seems to be working with Click To Expand
You are right it's with And here is the code i am calling : Future<void> _dealWithCredentials(OAuthCredential? credential) async {
if (credential != null) {
try {
UserCredential finalCredentials = await FirebaseAuth.instance.signInWithCredential(credential);
} on FirebaseAuthException catch (error) {
debugPrint("Error code : ${error.code}");
debugPrint("Error message : ${error.message}");
switch (error.code) {
case "user-not-found":
errorText =
Localization.instance.getText("wrong_email_or_password");
break;
case "user-disabled":
errorText =
"${Localization.instance.getText("account_disabled")}";
break;
case "account-exists-with-different-credential":
debugPrint("Already existing credentials : ${error.message}");
break;
}
}
}
} |
Thanks for the info. Unfortunately, it's not enough to reproduce the crash on my end. |
@Lyokone i am able to reproduce it locally at 100% in
I have understood the issue and the crash :
And i am able to reproduce it by clicking on Here is the full code :
So to fix it on my side it's simple, i simply need to do :
Before calling I will make a new release of my app to fix this. |
Fatal Exception: NSInvalidArgumentException |
I had this exact issue and thought it was a bug in the google_sign_in or firebase_auth package so I came to searching the issue tracker. The solution form @Tom3652 is 100% correct and I'm happy I was able to resolve the crasher with a simple change to my code. However, I also 100% agree that the library needs to do better. First, to have it crash a production app is bad enough but the fact that it works fine in debug mode and only crashes in release mode is really frustrating. Just my two cents, I appreciate you guys and whoever is maintaining these libraries. NOTE: I'm using Firebase_Auth 14.4.1, and Google_Sign_In 6.1.6 , and in iOS using Firebase 10.18.0. All were latest at this time. FWIW, when I get a null googleAuth object I'm returning a Also, I have all of this wrapped in a try/catch but that was not catching. The app crasher assertion is down in the native code.
|
We are encountering the same issue when cancelling Google Sign-In. Currently, the Google Sign-In package does not handle the exception at that time. However, we can handle this crash from our side. Please refer to the code below. Thank you for your patience as we address this issue.
|
Bug report
Describe the bug
I have received this report twice yesterday in my crashlytics dashboard.
I am not sure if this is a
firebase_crashlytics
issue or not but it saysCrashed: com.google.firebase.crashlytics.ios.exception
Here is the trace :
Click To Expand
Steps to reproduce
I have no idea how to reproduce it, my app is in beta test mode in TestFlight currently and it's another user that got this crash on iOS 16+ on iPhone 13 :
Expected behavior
The app should not crash
Flutter doctor
Run
flutter doctor
and paste the output below:Click To Expand
Flutter dependencies
Run
flutter pub deps -- --style=compact
and paste the output below:Click To Expand
The text was updated successfully, but these errors were encountered: