-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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_ec2_transit_gateway_route: Crash from externally deleted attachment #7111
Comments
One possible contributor is that the customer gateway was previously applied, but then manually deleted via the console before this started happening. |
Hey @mskucherawy 👋 Thanks for reporting this and sorry for the unexpected behavior here. Your additional context is super helpful! It looks like there's a typo in the resource code here: That logic should be checking |
Terrific! What's the timeline for that release? |
Pull request submitted: #7117 We have been releasing on a weekly cadence with an exception due to the year end holidays. |
… removed attachment Reference: #7111 Previous output from acceptance testing: ``` === CONT TestAccAWSEc2TransitGatewayRoute_disappears_TransitGatewayAttachment panic: runtime error: index out of range goroutine 1025 [running]: github.com/terraform-providers/terraform-provider-aws/aws.resourceAwsEc2TransitGatewayRouteRead(0xc0007f84d0, 0x42c6e00, 0xc000904700, 0xc0007f84d0, 0x0) /Users/bflad/go/src/github.com/terraform-providers/terraform-provider-aws/aws/resource_aws_ec2_transit_gateway_route.go:128 +0x8e6 github.com/terraform-providers/terraform-provider-aws/vendor/github.com/hashicorp/terraform/helper/schema.(*Resource).Refresh(0xc0004f8b60, 0xc0009630e0, 0x42c6e00, 0xc000904700, 0xc000547cb0, 0xc00071cf01, 0xc00074c550) /Users/bflad/go/src/github.com/terraform-providers/terraform-provider-aws/vendor/github.com/hashicorp/terraform/helper/schema/resource.go:352 +0x160 ``` Output from acceptance testing: ``` --- PASS: TestAccAWSEc2TransitGatewayRoute_disappears (310.87s) --- PASS: TestAccAWSEc2TransitGatewayRoute_basic (314.08s) --- PASS: TestAccAWSEc2TransitGatewayRoute_disappears_TransitGatewayAttachment (336.06s) ```
Until this ships, can you suggest a workaround? For example, do I have to delete or taint the running transit gateway resources via the console to get "plan" and "apply" working again? |
@mskucherawy you can use EDIT: Sorry you'll still have the same problem even after |
Thanks! Are there docs online anyplace about building custom local providers? |
This has been released in version 1.56.0 of the AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. |
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
Terraform Version
Terraform v0.11.10
Affected Resource(s)
We suspect one or more of these based on the debug trace:
resource "aws_ec2_transit_gateway"
resource "aws_ec2_transit_gateway_vpc_attachment"
resource "aws_customer_gateway"
resource "aws_vpn_connection"
resource "aws_ec2_transit_gateway_route_table"
resource "aws_ec2_transit_gateway_route_table_association"
resource "aws_ec2_transit_gateway_route"
Terraform Configuration Files
These are possibly proprietary. If after reviewing the debug output you do need these, please let me know and I'll get them to you somehow.
Debug Output
https://gist.github.com/mskucherawy/f06c1a4ad7a945a08b7d81b2acb0f4a3
Panic Output
No "crash.log" was produced. See debug output.
Expected Behavior
This should complete, or produce a meaningful error message if there's not actually a bug.
Actual Behavior
panic; see debug log.
Steps to Reproduce
terraform plan
Important Factoids
We're using the Transit Gateway stuff, which is new.
References
None (yet).
The text was updated successfully, but these errors were encountered: