-
Notifications
You must be signed in to change notification settings - Fork 9.7k
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
provider/aws: Fixed deletion of aws_api_gateway_base_path_mapping with empty path #10177
Conversation
@Ninir hi there! Nice catch! Thank you! |
@kwilczynski Do you have any hint about the diff issue? Still investigating, but missing something, for sure... Testing the same test under real conditions is fine (thus compiling and testing the compiled binary), and everything destroyed correctly. |
@Ninir let me have a look. I will report back. |
@kwilczynski Think I'v found it... when getting the base path mapping with the empty base_path option, here is what is happening in the background (from line 90):
However, the resulting mapping variable defined is empty, thus NOT setting the api_id attribute. This throws the error exposed above... |
df80e2d
to
4acc586
Compare
It should be all ok. |
Hi @Ninir Thanks for the work here - this doesn't pass the tests i'm afraid
P. |
4acc586
to
9d4adfe
Compare
Hi @stack72 Dang it, sorry for the overload for you! Just updated the test configuration & ran the 2 tests: $ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayBasePath_'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/12 21:31:58 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAPIGatewayBasePath_ -timeout 120m
=== RUN TestAccAWSAPIGatewayBasePath_basic
--- PASS: TestAccAWSAPIGatewayBasePath_basic (56.27s)
PASS
ok github.com/hashicorp/terraform/builtin/providers/aws 56.297s
$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSAPIGatewayEmptyBasePath_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2016/12/12 21:34:44 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSAPIGatewayEmptyBasePath_basic -timeout 120m
=== RUN TestAccAWSAPIGatewayEmptyBasePath_basic
--- PASS: TestAccAWSAPIGatewayEmptyBasePath_basic (21.37s)
PASS
ok github.com/hashicorp/terraform/builtin/providers/aws 21.395s Thanks for the review! |
Hi @Ninir This LGTM now - thanks for the fast fix :)
|
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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further. |
Fixes #9212
Here is the output when running it: