-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
Use aws-sdk-go-base/tfawserr
in internal packages
#13036
Conversation
This comment has been minimized.
This comment has been minimized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is fantastic. 🥇 🥇 🥇
This is great, @ewbankkit! What do you think about moving these error functions to |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
f4fbac1
to
9ba1f5d
Compare
This comment has been minimized.
This comment has been minimized.
9ba1f5d
to
30ad399
Compare
30ad399
to
daa3348
Compare
daa3348
to
f2a29e2
Compare
This comment has been minimized.
This comment has been minimized.
f2a29e2
to
b0d7c59
Compare
d9f94b6
to
3fe4a01
Compare
5feb11b
to
6e58e84
Compare
This comment has been minimized.
This comment has been minimized.
6e58e84
to
500fe77
Compare
500fe77
to
7c6a568
Compare
This comment has been minimized.
This comment has been minimized.
7c6a568
to
5f13d9f
Compare
5f13d9f
to
c73896a
Compare
Alias 'isAWSErr*' and 'isResource*Error' to functions in the internal errors package. Change the code generator, not the generated code. 'internal/errors' -> 'internal/tfawserror'. 'tfawserr.IsAWSErr' -> 'tfawserr.IsAWSErrCodeMessageContains'. Use 'hashicorp/aws-sdk-go-base/tfawserr' in keyvaluetags package. Run 'make gen'. Use 'hashicorp/aws-sdk-go-base/tfawserr' for 'isAWSErr*'. Use 'tfawserr.ErrCodeEquals' in '[Rr]etryOnAwsCode(s)'. Rename package for resource error functions. Fix after rebase.
c73896a
to
1e7c180
Compare
aws-sdk-go-base/tfawserr
in internal packages
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome!! 🚀
This has been released in version 3.10.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! |
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! |
Community Note
After all the work on the
aws-sdk-go-base/tfawserr
package that was initiated by the initial versions of this PR it can now be recast as changing theinternal
packages to use this new package instead of implementing private helpers.I have simplified this PR by not aliasing the
isAWSErr*
functions inawserr.go
and moving the Plugin SDKresource
helpers to a separate PR (#15477).Once this is merged I will add a technical debt issue to replace the
isAWSErr
calls with calls to functions inaws-sdk-go-base/tfawserr
.Release note for CHANGELOG:
Output from acceptance testing:
An example resource: