aws-amplify / aws-amplify/amplify-cli
Cognito identity provider's atrribute mapping keeps changing, causing error in triggers.
- Dominant language
- TypeScript
- Stars
- 2.9k
- Forks
- 825
- Avg merge
- 11d 23h
- Merged PRs (30d)
- 2
Description
### Before opening, please confirm:
- [X] I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
- [X] I have [searched for duplicate or closed issues](https://github.com/aws-amplify/amplify-cli/issues?q=is%3Aissue+).
- [X] I have read the guide for [submitting bug reports](https://github.com/aws-amplify/amplify-cli/blob/master/CONTRIBUTING.md#bug-reports).
- [X] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
### How did you install the Amplify CLI?
_No response_
### If applicable, what version of Node.js are you using?
_No response_
### Amplify CLI Version
7.4.5
### What operating system are you using?
Ubuntu
### Amplify Categories
auth
### Amplify Commands
update
### Describe the bug
Cognito atrribute mapping keeps changing. When using identity provider Oauth 2.0 like Google and Facebook. You can configure the Attribute mapping in your cognito console. After setting it up, I will use these attributes in my cognito triggers, such as custom user pool attributes. However, in production all of a sudden attribute mapping change, `name`, `picture`, `email_verified` no longer mapped. This will prevent user sign up and sign in while in production.
### Expected behavior
The attribute mapping doesn't change, so my cognito triggers can run smoothly.
### Reproduction steps
I have tried many ways to reproduce the bugs. I have tried isolating auth update and do the `amplify push`. But the attribute mapping doesn't change, So yeah, I can't find it. But I am very certain it is there. It will always show up when I am trying to do a product demo. So yeah, that's a painful bug.
### GraphQL schema(s)
```graphql
# Put schemas below this line
```
### Log output
```
# Put your logs below this line
```
### Additional information
_No response_
Contributor guide
Research direction
Start with the auth flow described in the issue, especially `amplify update` followed by `amplify push`, and compare the configured Cognito identity-provider mappings with the production state. Reproduce the OAuth setup with Google or Facebook and verify whether `name`, `picture`, and `email_verified` remain mapped so the Cognito triggers can use them.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, typescript
- Domain
- authentication, cli, cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100