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

r/aws_api_gateway_rest_api: Crash when binary_media_types = [""] #31827

Closed
ewbankkit opened this issue Jun 7, 2023 · 3 comments · Fixed by #32169
Closed

r/aws_api_gateway_rest_api: Crash when binary_media_types = [""] #31827

ewbankkit opened this issue Jun 7, 2023 · 3 comments · Fixed by #32169
Labels
bug Addresses a defect in current functionality. crash Results from or addresses a Terraform crash or kernel panic. service/apigateway Issues and PRs that pertain to the apigateway service.
Milestone

Comments

@ewbankkit
Copy link
Contributor

ewbankkit commented Jun 7, 2023

Terraform AWS Provider v5.1.0:

resource "aws_api_gateway_rest_api" "example" {
  body = jsonencode({
    openapi = "3.0.1"
    info = {
      title   = "example"
      version = "1.0"
    }
    paths = {
      "/path1" = {
        get = {
          x-amazon-apigateway-integration = {
            httpMethod           = "GET"
            payloadFormatVersion = "1.0"
            type                 = "HTTP_PROXY"
            uri                  = "https://ip-ranges.amazonaws.com/ip-ranges.json"
          }
        }
      }
    }
  })

  name = "example"

  binary_media_types = [""]
  endpoint_configuration {
    types = ["REGIONAL"]
  }
}

Crash:

panic: interface conversion: interface {} is nil, not string

goroutine 483 [running]:
github.com/hashicorp/terraform-provider-aws/internal/service/apigateway.resourceRestAPIUpdate({0xf139e40, 0xc006c847b0}, 0xc007fbfa80, {0xdc1b800?, 0xc00038b800?})
  github.com/hashicorp/terraform-provider-aws/internal/service/apigateway/rest_api.go:409+0x2f74
github.com/hashicorp/terraform-provider-aws/internal/provider.interceptedHandler[...].func1(0x0?, {0xdc1b800?, 0xc00038b800?})
  github.com/hashicorp/terraform-provider-aws/internal/provider/intercept.go:108 +0x178
...
Error: The terraform-provider-aws_v5.1.0_x5 plugin crashed!
@github-actions
Copy link

github-actions bot commented Jun 7, 2023

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@ewbankkit ewbankkit changed the title r/aws_api_gateway_rest_api: Crash when binary_media_types = [""] r/aws_api_gateway_rest_api: Crash when binary_media_types = [""] Jun 7, 2023
@ewbankkit ewbankkit added crash Results from or addresses a Terraform crash or kernel panic. service/apigateway Issues and PRs that pertain to the apigateway service. bug Addresses a defect in current functionality. labels Jun 7, 2023
@github-actions github-actions bot added this to the v5.5.0 milestone Jun 22, 2023
@github-actions
Copy link

This functionality has been released in v5.5.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. Thank you!

@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 23, 2023
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. crash Results from or addresses a Terraform crash or kernel panic. service/apigateway Issues and PRs that pertain to the apigateway service.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant