-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
onActivityResult not fired! #182
Comments
Just update to 0.4.1 - same issue. Cancel result fires on a back button. |
Same issue, but it was my fault. Check in your NOTE: Developers need a warning if missing! |
i have |
@Fax3D have you added your SHA1 and package name in the Firebase console and downloaded the |
Hi @samtstern, yes i've added my SHA1 and i've downloaded the Thanks |
I had this problem too! Turned out it was caused by not having internet connectivity on the device. The email auth provider would then throw an internal error and the activity would not finish. |
I'm having this issue. Anyone find a good work around? |
@Fax3D do you see anything in the logs like "Firebase sign in with credential unsuccessful" or any mention of error code 12501? |
I'm actually having the same issue, using 9.0.2 with 0.4.1. I can login fine with email, but not Google . I do not get anything back in the onActivityResult |
I'm having the same issue as @tehras |
@tehras @NicholasSTG did you enable Google Auth in the 'providers' tab of the Firebase Console? Did you enter the correct SHA1 and package name? |
I did on both accounts. I also just double checked the console and my google-services.json account to make sure. |
@nichola I was missing the Google play services auth library |
@tehras it seems that was my issue as well; once I did that and updated a few other libraries (and rebuilt the heck out of the project) it seems to be working. |
Looks like @tehras and @NicholasSTG have solved their issue. @Fax3D is the issue persisting for you? If not we can close this issue. |
Hi @samtstern, i've just checked my configuration like proposed by @tehras and @NicholasSTG and seems to be ok, it's all up to date and i've already play services auth library... and the issue still persist! Thanks! |
Hi @samtstern, looking into logs, i found this exception:
|
I see the same issue, but on a Samsung S6 only (G920F / Android 6.0.1). The google registration works OK but the onActivityResult() callback is never fired. That's a major issue since my app is doing some mandatory initializations in this callback... |
In my case, I just had not added the correct SHA key to the Google Services json and it works now. Would be nice to get an error message though.... |
This issue still persist in version 0.4.3... anyone? Thanks. |
I was chasing down a similar bug for a long time, but it was an issue with my activity lifecycle. I had some code in my onStart() method which checked if a user was logged in, and if so moved to another activity. This was bypassing the onActivityResult() method. Moving my log in check into the onResume() method allowed onActivityResult() to be fired properly. FYI, I was following this guidance, which does not specify what part of the Activity lifecycle is best to check the log in status. It was my fault that I didn't know whe onActivityResult() is called! |
Hi I am using Firebase UI 0.4.4 and Play Services 9.4.0
onActivityResult is not being fired, Facebook and Email auth is working fine. I have added SHA-1 key and also enabled google login in firebase console, plus google json config file is updated and at right place. Please any can help? |
Here is the log's but I am unable to get a hint of whats happening...
|
I was struggling with this for a while and I had a combination of factors (some may be irrelevant but I caught them when debugging this issue nevertheless):
Hope this helps. |
Any login method makes my app to close. No error msg is printed. It just closes. |
I am having the same reaction as fabriciointerama. Upon entering the email/name/password and then pressing next it closes my app to the background. Bringing the app back to the foreground just runs through the lifecycle where it eventually hits the start up check to see if a user is logged in. Since the authentication was successful it forwards to the main activity but this means that onActivityResult is never ever triggered. This is quite annoying. Further working with this, Google login lets me select an account, and then the dialog closes and nothing, it just sits on the screen to choose facebook/google/email login. Facebook login gives me an error saying my app id is change me when I created my facebook app id string in my string resources file, I assume it isn't looking for it. |
Don't silently fail if Google Sign In fails firebase#182
Don't silently fail if Google Sign In fails firebase#182
Don't silently fail if Google Sign In fails firebase#182
Hi, we encountered the same issue.
We encountered the problem only on the second one (with JDK 1.8): is there anyone who experienced the issue with JDK 1.7? Or, is there anyone that is able to login with an app compiled on a pc that runs JDK 1.8? |
@tmontanaro Thanks for the comment! I have a bunch of questions which might help get to the bottom of this. Are you seeing this when using sign in with google Google like @Fax3D? Can you log in using other providers? Are you running in an emulator, or are you seeing this on a device? I have JDK 1.8 installed and it works for me so unfortunately I think that may not be the issue. |
Hello, I will answer to your question in a list to avoid misanderstanding.
|
@tmontanaro although this does seem to be device specific for you, the computer can also matter because each machine will have its own debug keystore and therefore require a different SHA1 registration (unless you are explicitly sharing the keystore across machines). |
Hello, I must apologize: all our (my and my team's) problems were related to the keystore (thank you very much @samtstern ... without you we would have continued to try without success): one of our colleagues changed the SHA1 code on firebase for some personal trials (without warning us) and then we started to have problems. |
I'm having the same issue as @fabriciointerama however, the most strange thing is that my login process works perfectly fine in Facebook, Gmail and normal email. Even signing anonymously works. But right after the login is successful, my app (not the activity) is moved to the background. I have to see the apps in the background, and after selecting my app, it resumes the activity that fired the login process (which is my starting activity) and it continues to the main activity. So login is working perfectly fine. I see the emails that have logged in for all those authentication providers. But the app gets closed immediately after log in, leaving me at the desktop. I'm using the latest versions for the dependencies. This is my app build.gradle:
|
Yesterday I forgot to mention that I had reviewed @janakagamini comment, so just to double check and discard possible missing configurations, here is the 'whole' picture:
So summarizing my situation again, apparently the configuration is all right. However, after a successful login, my app moves to the background, leaving me at the desktop of my Android emulator (tested as well on a physical device with the same result). I'm using the default Firebase Auth UI. The code I use to start the activity is this one:
|
@dcalano did you solve your problem? It definitely seems mine is like yours. |
I'm facing similar behaviour. Changing solves the issue. I hope appcompat library will be fixed soon. |
I was having this issue because I had set no history for the activity calling the firebase ui in the manifest file. Removing |
@itrevex actually I have the noHistory attribute set to true. Thanks for this valuable data! Although at the end I built my own customized login / sign up process using the Firebase library. |
Actually make sure that private static final int RC_SIGN_IN =1 ; |
I had the same issue; In my case the problem was that I was trying to login from fragment and passing to google sign in client activity as context and listening onActivityResult inside activity, then I change: val googleSignInClient = GoogleSignIn.getClient(requireActivity(), gso) to val googleSignInClient = GoogleSignIn.getClient(requireContext(), gso) and listen onActivityResult inside fragment and it triggered. |
I'm using the new version 0.4.1 of the auth library (on a device with Android 6.0.1).
I'm trying to use the Google sign in provider, launching this intent:
When i login with email&password everythings works fine, but when i try to login with the google sign in button, i select the account and i can see a loader for about 3-4 seconds: then the loader disappears and nothing else happens, i still remain into the activity with the two login buttons.
onActivityResult
isn't fired and i don't know if login was successful or not.Thanks.
The text was updated successfully, but these errors were encountered: