MaikuB / flutter_appauth

A Flutter wrapper for AppAuth iOS and Android SDKs
269 stars 238 forks source link

Not redirecting to the app after google sign in. (Android only, Works as intended in iOS) #451

Open yhbsh opened 9 months ago

yhbsh commented 9 months ago

I Want to add google sign in to my flutter app. I Followed the instruction in the README.md, step by step. New google cloud project. generate client id. configure consent screen. implement the appauth in flutter.

Works well on ios. but on Android it does not. the sign in is completed and the login does not redirect back to the app. i don't know what to do.

LouisDeGuinness commented 9 months ago

+1

Same behavior on my side, iOS working correctly, Android not redirecting after login.

TJohnRun commented 9 months ago

I ran the flutter_appauth demo app in an Android 13 SDK 33 and SDK environment and the result is the same. iOS works fine. Android fails to return to the app.

https://github.com/MaikuB/flutter_appauth/assets/24813524/78fdba44-1e49-4ea1-9c3e-fce0be5e98ff

XNORGATE commented 9 months ago

same here , i find out someone is doing this https://stackoverflow.com/questions/76971239/supabase-auth-redirects-to-google-com-instead-of-my-app

but i haven't realized what should i put into the account_id , i've put the applicationId but it didn't works.

LouisDeGuinness commented 9 months ago

After double-checking the "appAuthRedirectScheme" in the build.gradle of the android app and the "redirectUrl" parameter of the authorize method the problem is gone.

Why iOS was working though, no clue.