Skip to content
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

resource/aws_cognito_user_pool: Fix perpetual diffs on sms_verification_message #9758

Merged
merged 2 commits into from
Sep 6, 2019

Conversation

nywilken
Copy link
Contributor

@nywilken nywilken commented Aug 13, 2019

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" comments, they generate extra noise for pull request followers and do not help prioritize the request

No specific issues found that pertaining to this bug.

Release note for CHANGELOG:

* resource/aws_cognito_user_pool: Fix perpetual diffs on sms_verification_message

When using verification_message_template.sms_message for setting the sms message verification template the resource upon subsequent applys will trigger an update because of a diff in the conflicting sms_verification_message argument. This changes adds the computed property onto sms_message_verification to ensure it get's updated with the contents being set by verification_message_template.sms_message

Acceptance test before change

--- FAIL: TestAccAWSCognitoUserPool_withVerificationMessageTemplate (10.90s)                                                                                                                                                         [274/322]
    testing.go:568: Step 0 error: After applying this step, the plan was not empty:

        DIFF:

        UPDATE: aws_cognito_user_pool.pool
          sms_verification_message:                                "{####} Baz" => ""

Acceptance test after change

--- PASS: TestAccAWSCognitoUserPool_withVerificationMessageTemplate (27.79s)                                                                                         

@nywilken nywilken requested a review from a team August 13, 2019 19:09
@ghost ghost added the size/XS Managed by automation to categorize the size of a PR. label Aug 13, 2019
@nywilken nywilken requested a review from a team August 13, 2019 19:09
@ghost ghost added service/cognito tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Aug 13, 2019
@nywilken nywilken removed the request for review from a team August 13, 2019 19:27
@nywilken nywilken added the bug Addresses a defect in current functionality. label Aug 13, 2019
@nywilken nywilken force-pushed the b-aws_cognito_user_pool-sms-verification-message branch from 35ad1cc to 14c7a81 Compare August 13, 2019 19:46
@aeschright aeschright self-assigned this Aug 14, 2019
@aeschright
Copy link
Contributor

I talked the PR through with @bflad because I wanted to make sure I understood why we're handling these attributes in this way, and from our discussion I made a follow-up item to discuss: #9791

@nywilken
Copy link
Contributor Author

nywilken commented Sep 3, 2019

@aeschright should this PR be retracted in favour of the longer term solution specified in #9791

@aeschright
Copy link
Contributor

@nywilken No, it would be a breaking change so let's go ahead with this and come back to #9791 when we're closer to a major release.

…on_message

When using `verification_message_template.sms_message` for setting the sms message verification template the resource upon subsequent applys will trigger an update because of a diff in the conflicting `sms_verification_message` argument. This changes adds the computed property onto `sms_message_verification` to ensure it get's updated with the contents being set by `verification_message_template.sms_message`

Acceptance test before change
```
--- FAIL: TestAccAWSCognitoUserPool_withVerificationMessageTemplate (10.90s)                                                                                                                                                         [274/322]
    testing.go:568: Step 0 error: After applying this step, the plan was not empty:

        DIFF:

        UPDATE: aws_cognito_user_pool.pool
          sms_verification_message:                                "{####} Baz" => ""

```

Acceptance test after change
```
--- PASS: TestAccAWSCognitoUserPool_withVerificationMessageTemp
```
@nywilken nywilken force-pushed the b-aws_cognito_user_pool-sms-verification-message branch from 14c7a81 to ac48305 Compare September 4, 2019 19:31
@ghost ghost added size/S Managed by automation to categorize the size of a PR. and removed size/XS Managed by automation to categorize the size of a PR. labels Sep 4, 2019
@nywilken nywilken force-pushed the b-aws_cognito_user_pool-sms-verification-message branch from ac48305 to a20cadf Compare September 4, 2019 19:33
Copy link
Contributor

@aeschright aeschright left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If someone else can run the tests (my connection is being weird) this is good to go. Thanks!

aws/resource_aws_cognito_user_pool_test.go Show resolved Hide resolved
@nywilken nywilken force-pushed the b-aws_cognito_user_pool-sms-verification-message branch from a20cadf to b0c5ef4 Compare September 4, 2019 21:26
@nywilken nywilken added this to the v2.28.0 milestone Sep 6, 2019
@nywilken nywilken merged commit 83739d2 into master Sep 6, 2019
@nywilken nywilken deleted the b-aws_cognito_user_pool-sms-verification-message branch September 6, 2019 14:45
nywilken added a commit that referenced this pull request Sep 6, 2019
@ghost
Copy link

ghost commented Sep 12, 2019

This has been released in version 2.28.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks!

@ghost
Copy link

ghost commented Nov 1, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked and limited conversation to collaborators Nov 1, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. size/S Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants