Error: A non-recoverable sign in failure occurred -- Tried all the solutions and none of them work
See original GitHub issueHere’s my code:
`GoogleSignin.configure({ scopes: [“https://www.googleapis.com/auth/userinfo.profile”],//scopes as you need webClientId: “ID”, //iosClientId: <FROM DEVELOPER CONSOLE>, // only for iOS //offlineAccess: true, //(give it true if you need serverAuthCode i.e cross client authorisation) //hostedDomain: ‘’ forceConsentPrompt: true // [Android] if you want to show the authorization prompt at each login //accountName: ‘’ }) onGoogleLogin = async () => { const {idToken} = await GoogleSignin.signIn(); const googleCredential = auth.GoogleAuthProvider.credential(idToken); return auth().signInWithCredential(googleCredential); }; <Button title=“Login with Google” onPress={() => this.onGoogleLogin().then(user => {loginUserSuccess(user); this.props.navigation.navigate(‘Home’)}) } />
`
Expected Behavior
I expect it to show the login screen.
Actual Behavior
Reproduces this error:
Error: A non-recoverable sign in failure occurred fn@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:2102:45 signIn$@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:160347:72 tryCatch@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:25669:23 invoke@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:25844:32 tryCatch@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:25669:23 invoke@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:25745:30 http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:25755:21 tryCallOne@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:27024:16 http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:27125:27 _callTimer@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:30579:17 _callImmediatesPass@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:30615:19 callImmediates@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:30834:33 callImmediates@[native code] __callImmediates@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:2591:35 http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:2368:34 __guard@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:2574:15 flushedQueue@http://10.0.3.2:8081/index.bundle?platform=android&dev=true&minify=false:2367:21 flushedQueue@[native code] callFunctionReturnFlushedQueue@[native code]
Environment
- react-native version: 0.61.3
- @react-native-community/google-signin version: ^4.0.3
- version of Android, gradle, android plugin for gradle: Android 9, gradle 5.4.1, 3.5.1
I have tried all the solutions. The support email is defined, the keys are all there, and everything’s a-ok. It just won’t work. I’ve tried with and without VPN. What is the issue?
Issue Analytics
- State:
- Created 3 years ago
- Comments:9 (4 by maintainers)
Top Related StackOverflow Question
After almost 2 days of trying to work this out I decided to create a new Google account, start a new project on Firebase and write my entire project from scratch and I finally got it working. While I wasn’t able to specifically pinpoint what was giving me the error, I can still leave some pointers for anyone who finds themselves in the same position i did:
Make sure you’re using the WebClientId given in Firebase (Authentication > Sign-in method > Google > Web SDK configuration)
Make sure GoogleSignin.configure is being invoked in the first place.
Make sure Google is enabled as a Sign-in provider in Firebase.
Supposedly the best way to generate SHA1 key is
keytool -keystore ./android/app/debug.keystore -list -v(it worked for me). If that doesn’t work go to the android folder and run./gradlew signingReportand copy all SHA1 keys.Make sure you’ve added a support email in Firebase.
Make sure you have the updated google service json file.
react-native: 0.62.2 react-native-community/google-signin: 4.0.3
Same here. I’ve tried every solution mentioned in various stackoverflow posts/github issues as well as the fix in the docs but the problem still persists. In my case, the login screen shows up but when i actually try to login, it fails with the aforementioned error.