-
Notifications
You must be signed in to change notification settings - Fork 163
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
something went wrong #332
Comments
Facing the same issue with error code 10 |
I also faced the same problem |
just now i clear it that issue! https://velog.io/@agnusdei1207/angular-ionic-capacitor-google-oauth2-plugin-feat.-android-ios sha-1 key issue..! The sha-1 key continues to change depending on how it is generated. |
Same problem here... |
I was struggling with this error for hours!!! But then, while checking the demo and following the readme.md, I realized that I was missing a configuration in a file: android/app/src/main/res/values/strings.xml In the demo, you can find it at: https://github.com/CodetrixStudio/CapacitorGoogleAuth/blob/master/demo/android/app/src/main/res/values/strings.xml Once I added the with the Google clientId, everything started to work :) Good day <3 |
Finally managed to make it work!!
WE ARE NOT GOING TO USE THE ANDROID KEY BUT WITHOUT IT CapacitorGoogleAuth WILL NOT WORK. in your app just use your Error 10 comes from Google API exception, and it signals that the android package name and sha1 are not valid |
Thank you @alon42, this worked for me. To further clarify step 2 for the next person the SHA1 I needed was specifically the one under |
Thank you so much @alon42, It finally worked ! |
I have done all of the above and even followed @agnusdei1207 's awesome instructions and still I get Something went wrong Error 10. |
@kristophbarbour I was desperate enough to find its source code when I searched for this problem 3 weeks ago, and it comes from having bad Android credentials. when there is something wrong with your ApplicationId with the SHA1. make sure you are using: a. google WEB credentials in the Capacitor config. |
Actually, i am also totally confused about google signing in ionic app but, i got to know solution by several tries, i finally discovered that the debug keystore SHA1 only works in the emulator Here, 1.debug keystore SHA1 works only in emulator (to get debug keystore SHA1 in terminal enter this commands cd android and then ./gradlew signInReport)
we should change SHA1 of Android SHA-1 signing certificate fingerprint. accordingly, in https://console.cloud.google.com (APIs & Services>>Credentials>>OAuth 2.0 Client IDs) Please make sure clear app data and try 2 times while checking login functionality |
Please check #332 (comment) |
|
|
|
I managed to use the GoogleAuth plugin on Android, but it only worked with the debug version (simulator or actual device), but the same build failed on the release version. Using @Raja-Malli-Dileep-Vadde #332 (comment), I FINALLY SUCCEEDED BY MANUALLY ADDING THE SHA-1 FROM GOOGLES PLAY-STORE AND ADD IT ONTO A NEW CREDENTIAL IN GCS (all without pushing a new version!). Steps:
By the way, does this belong to the official instructions? @reslear @fullstackduck |
I have the same issue but I can't solve. My problem is for Android device only. iOS is ok What about angular config and files: Angular init: capacitor.config.ts
google-services.json file into my ionic app into .\android\app\google-services.json Please help me |
|
Yes, correct. I tried but not works :( Are you available for premium support? If you can and you want help me, send me your private contact, please |
@lsantaniello Sorry, I'm just a struggling developer like you :| |
if you want we can schedule a working session in order to solve the issue all together |
I was developing a second version of my ionic/capacitor app. I wanted to start fresh, so created a new project and copied over all the necessary configs. Finally the config mentioned above sorted it out. Maybe because I switched the GoogleAuth plugin to a newer one. I ran into code 10 when I was working on the first version, and went through all the SHA1 setup and all. |
I not solved! |
I finally got it to work, @Raja-Malli-Dileep-Vadde was right.
In the end, for my case I'll keep two different Android OAuth client IDs. One for dev (emulators) and one for prod (play store). This is really annoying, I spent a few days solving this, but thank you to the amazing community that shares knowledge and helps everyone grow. You rock! |
Update, for everyone else figuring this out: In my latest version I realized that I do not need at all the android Oauth client id. Only configuring the server client id is enought (basically the web oAuth client id). Place that client id on the values.xml file and on your capacitor config, and then build the app. This is only for android devices |
Not sure if this has been said but... if you plan to release your app with google authentication in the play store, you have to get the SHA1 that is in the final APK. That is you have to download the APK from the google play store and run keytool -printcert -jarfile file.apk to get the SHA1, configure it in the Google Cloud Console and it will work |
Do not forget to migrate to the new lib who implements Google auth latest lib, is well documented around this: |
|
error Error: Something went wrong
at returnResult (VM3:912:32)
at win.androidBridge.onmessage (VM3:887:21)
The text was updated successfully, but these errors were encountered: