Login with google for the second time : email Attribute cannot be updated
See original GitHub issueDescribe the bug I have the same problem as this #issue. If you make a user pool with required email field then the second google login attempt fails. changing required fields after creating UserPool is not possible and deleting the UserPool and making a new one doesn’t look like a good solution to me because by doing it I will lose all my user’s data!
To Reproduce
- Make a new UserPool with email attribute as required field
- Enable Google federation in UserPool
- Try to login for the second time using hosted ui
- It should give you this error:
email Attribute cannot be updated.
Expected behavior When we use same email address it shouldn’t update email attribute!
Issue Analytics
- State:
- Created 4 years ago
- Reactions:2
- Comments:24 (5 by maintainers)
Top Results From Across the Web
Amazon Cognito throws an error if I try to sign in a second time ...
The first time a user sign in with Google, a new user is correctly created in Cognito, but if I try to sign...
Read more >Aws Cognito throws an error if I try to sign in a second ... - Reddit
The first time a user sign in with Google, a new user is correctly ... =Invalid+user+attributes%3A+email%3A+Attribute+cannot+be+updated.
Read more >Signing up and confirming user accounts - Amazon Cognito
Updating the user's attributes to indicate that the email address or phone number is verified. To view this information, you can use the...
Read more >About SSO - Google Workspace Admin Help
SSO lets users sign in just one time to get access to all their ... then access Google apps directly without a second...
Read more >Common Errors - Ads API - Google Developers
Go to the Google API Console and navigate to the OAuth consent screen. Then change the publishing status to In production following these...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It seems after two years of my report, you guys still don’t fix it @sammartinez Actually, I moved away from Cognito a long time ago and can’t test it anymore. It was a horrible experience with a lot of bugs and a lack of necessary features
I can reproduce the same issue. email is not mandatory for my pool, and is selected as readable and writable by my app client. First time login succeeds (and the email attribute on my Cognito user is populated), subsequent logins fail with ‘user+attributes%3A+email%3A+Attribute+cannot+be+updated’ error.
I worked around it by creating a custom attribute called ‘emailaddress’ and mapped the Google email attribute to that.