Open robert-stevens opened 4 years ago
Hi,
I have cloned the example app and I have added awsconfiguration.json file with my cognito info.
I then tried using sign up (i.e. email + password) and this worked, and my user was shown in my user pool.
I then added in google_sign_in package:
google_sign_in: ^4.2.0
And did the necessary config.
I ended up using the code below:
signInGoogle() async { final dynamic result = await signInWithGoogle(); Cognito .federatedSignIn('accounts.google.com', result.idToken) .then((res) { print(res); }).catchError((dynamic error) { print(error); }); }
I get a "flutter: UserState.SIGNED_IN" back and the state shows that I'm signed in.
I then go under my groups, e.g.
Groups => eu-west-xxx_Google
But I don't see the user.
I don't have any errors in the app, and so was wondering if you could point me in the right direction to get this working.
Thanks, Robert
Update:
From what I see the user is not logged in, although the federatedSignIn simply returns "UserState.SIGNED_IN" as a response.
Did you get a solution to this?
Hello, this is a bug in upstream - https://github.com/aws-amplify/aws-sdk-android/issues/685#issuecomment-460349130
@robert-stevens Using Hosted UI should fix this.
Hi,
I have cloned the example app and I have added awsconfiguration.json file with my cognito info.
I then tried using sign up (i.e. email + password) and this worked, and my user was shown in my user pool.
I then added in google_sign_in package:
And did the necessary config.
I ended up using the code below:
signInGoogle() async { final dynamic result = await signInWithGoogle(); Cognito .federatedSignIn('accounts.google.com', result.idToken) .then((res) { print(res); }).catchError((dynamic error) { print(error); }); }
I get a "flutter: UserState.SIGNED_IN" back and the state shows that I'm signed in.
I then go under my groups, e.g.
But I don't see the user.
I don't have any errors in the app, and so was wondering if you could point me in the right direction to get this working.
Thanks, Robert
Update:
From what I see the user is not logged in, although the federatedSignIn simply returns "UserState.SIGNED_IN" as a response.