@@ -94,6 +94,10 @@ func SkipSweepError(err error) bool {
9494 if tfawserr .ErrMessageContains (err , "InvalidParameterValueException" , "Access Denied to API Version" ) {
9595 return true
9696 }
97+ // Example (GovCloud): InvalidParameterException: The DATA_PROTECTION_POLICY policy type is not supported in this region
98+ if tfawserr .ErrMessageContains (err , "InvalidParameterException" , "DATA_PROTECTION_POLICY policy type is not supported in this region" ) {
99+ return true
100+ }
97101 // Example (GovCloud): The AppStream 2.0 user pool feature is not supported in the us-gov-west-1 AWS Region
98102 if tfawserr .ErrMessageContains (err , "InvalidParameterValueException" , "feature is not supported" ) {
99103 return true
@@ -102,6 +106,10 @@ func SkipSweepError(err error) bool {
102106 if tfawserr .ErrMessageContains (err , "InvalidParameterValueException" , "This API operation is currently unavailable" ) {
103107 return true
104108 }
109+ // Example (GovCloud): InvalidSignatureException: Credential should be scoped to a valid region
110+ if tfawserr .ErrMessageContains (err , "InvalidSignatureException" , "Credential should be scoped to a valid region" ) {
111+ return true
112+ }
105113 // For example from us-west-2 Route53 zone
106114 if tfawserr .ErrMessageContains (err , "KeySigningKeyInParentDSRecord" , "Due to DNS lookup failure" ) {
107115 return true
@@ -114,6 +122,10 @@ func SkipSweepError(err error) bool {
114122 if tfawserr .ErrMessageContains (err , "ResourceNotFoundException" , "The subscription does not exist" ) {
115123 return true
116124 }
125+ // Example (GovCloud): SignatureDoesNotMatch: Credential should be scoped to a valid region
126+ if tfawserr .ErrMessageContains (err , "SignatureDoesNotMatch" , "Credential should be scoped to a valid region" ) {
127+ return true
128+ }
117129 // For example from us-gov-east-1 IoT domain configuration
118130 if tfawserr .ErrMessageContains (err , "UnauthorizedException" , "API is not available in" ) {
119131 return true
0 commit comments