I have been following this tutorial to get Google SignOn going: https://developers.google.com/identity/sign-in/android/start-integrating
When I run my application locally with a virtual device it works fine but when I deploy it to my device via debugging or if I generate a signed jar file and copy it manual GoogleSignInResult
always returns false
with an INTERNAL ERROR
message.
I'm struggling since quite a while to be able to use google login when deploying the application via debug to my device. Any help is highly appreciated!
Solution for My Issue:
Where you download the json file you have to copy past the code that you can generate with the java key tool. I totally missed that a few times in a row.
Press Ctrl + Alt + F5 (or Shift + F9 ) to launch the app in debug mode. Choose Run -> Attach to process and select the signature of an app to enable the debug mode, which is already installed via adb.
How do I turn on debug mode on device? First, enable Android developer options. Then, open Google Settings and select Nearby. Finally, tap on the gear icon and enable the "Include debug results" entry.
You are probably missing dev console registration. It's very common developers will have multiple signing cert configuration: debug key store, test environment signing cert, production signing cert. signing cert SHA1 + package name uniquely identifies an Android client and needs to be registered individually in dev console.
See below blogpost to understand more about OAuth clients registration:
http://android-developers.blogspot.com/2016/03/registering-oauth-clients-for-google.html
Or see this post: Test google signin on Android in development phase
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With