Getting false in results success
if (requestCode == RC_SIGN_IN) {
GoogleSignInResult result = Auth.GoogleSignInApi.getSignInResultFromIntent(data);
Log.d(TAG, "handleSignInResult:" + result.isSuccess());
if (result.isSuccess()) {
// Google Sign In was successful, authenticate with Firebase
GoogleSignInAccount account = result.getSignInAccount();
firebaseAuthWithGoogle(account);
} else {
// ...
}
}
}
handleSignInResult:false
tried out many ways but cant find out the solution,there is any solution for these..
Thanks in Advance
@yokei15 I need some more information to debug this. What other output do you see in adb logcat and can you try adding a statement like this for more info:
Log.d(TAG, "handleSignInResult:" + result.getStatus().toString());
It's likely an issue with your SHA1 and package name, but can't say for sure yet.
@samtstern Is SHA1 key to be update in firebase auth as well as in google developer console???
these was the shown in adb logcat
W/DynamiteModule: Local module descriptor class for com.google.firebase.auth not found.
D/Googlesignin: onActivityResult, requestCode: 9001, resultCode: 0
D/Googlesignin: handleSignInResult:false
@yokei15 you need to make sure your SHA1 and package name are listed in the Firebase console.
Could you show how you're creating your GoogleSignInOptions?
@samtstern Yes,Provided SHA! & Pakage Name correctly but same error in logcat (i.e) result is false
these was the code which i used
GoogleSignInOptions gso = new GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN)
.requestIdToken(getString(R.string.default_web_client_id))
.requestEmail()
.build();
mGoogleApiClient = new GoogleApiClient.Builder(this)
.enableAutoManage(this, this)
.addApi(Auth.GOOGLE_SIGN_IN_API, gso)
.build();
@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
// Result returned from launching the Intent from GoogleSignInApi.getSignInIntent(...);
if (requestCode == RC_SIGN_IN) {
GoogleSignInResult result = Auth.GoogleSignInApi.getSignInResultFromIntent(data);
Log.d(TAG, "Result:" + result.isSuccess());
if (result.isSuccess()) {
// Google Sign In was successful, authenticate with Firebase
GoogleSignInAccount account = result.getSignInAccount();
firebaseAuthWithGoogle(account);
}
}
}
I had the same problem with my androiddebugkey SHA1.
As a workaround, I had to create new OAuth 2.0 client ID for my app on Credentials page in the API Console as a Web application and use that client ID in my Android app.
Basically, this post at the stackoverflow has some workaround suggestions for this issue.
@mussa-ibragimov so you had to replace default_web_client_id with a web Client ID you created yourself?
This issue has been inactive for a very long time, going to close it. Please feel free to re-open if you have more relevant information.
Hi,
I am having issue while calling getSignInResultFromIntent(). In onActivityResult It receive StatusCode=9001 and ResultCode=SUCCESS.
GoogleSignInResult res=Auth.GoogleSignInApi.getSignInResultFromIntent(data);
handleResult(res);
But res.isSuccess() return false. I dont know why??
I am using Huawie Phone and google play version 9.8.0.
Please help.
@alihussain check res.getException() for more information
@samtstern Android Studio was signing apk with different key then i input in google console. I configured the debug key in Android studio and now everything is fine. Thanks.
please add SHA-1 Key on fire base project and try i hope solved problem
I am facing same issue. But different scenario, I have created a signed apk and installed in phone and then it is working fine. But when i upload on play store & then download and then it is returning false result. Please help. Thanks.
Try sign in the Android Studio using Firebase Android Studio plugin. I observed, only the the Firebase recognized you app signature and also the Play store.
Thanks for your reply. But still not able to resolve it.
Try to add both md5 and sha1 key into the firebase signing. Make sure its corresponding release keys.
Sent from Yahoo Mail on Android
On Sat, Feb 2, 2019 at 6:23 PM, rakeshkumar217notifications@github.com wrote:
Thanks for your reply. But still not able to resolve it.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
Most helpful comment
@samtstern Is SHA1 key to be update in firebase auth as well as in google developer console???
these was the shown in adb logcat
W/DynamiteModule: Local module descriptor class for com.google.firebase.auth not found.
D/Googlesignin: onActivityResult, requestCode: 9001, resultCode: 0
D/Googlesignin: handleSignInResult:false