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

[Bug]: Error: The terraform-provider-aws_v4.61.0_x5 plugin crashed! interface conversion: interface {} is string, not []interface {} #30372

Closed
bendotexe opened this issue Mar 31, 2023 · 3 comments · Fixed by #30379
Labels
bug Addresses a defect in current functionality. crash Results from or addresses a Terraform crash or kernel panic. regression Pertains to a degraded workflow resulting from an upstream patch or internal enhancement. service/rds Issues and PRs that pertain to the rds service.

Comments

@bendotexe
Copy link

Terraform Core Version

1.4.1

AWS Provider Version

4.61

Affected Resource(s)

aws_rds_cluster
aws_lambda_function

Though it seems to be an issue regardless of what's being changed.

Expected Behavior

Lambda should have updated in place with a new image.
Aurora should have updated it's master secret.

Actual Behavior

Terraform failure in CI/CD pipeline:

│ Error: Plugin did not respond

│ with aws_rds_cluster.this,
│ on 30-database.tf line 1, in resource "aws_rds_cluster" "this":
│ 1: resource "aws_rds_cluster" "this" {

│ The plugin encountered an error, and failed to respond to the
│ plugin.(*GRPCProvider).ApplyResourceChange call. The plugin logs may
│ contain more details.


│ Error: Plugin did not respond

│ with aws_lambda_function.data_retrieval,
│ on 50-service-data-fetcher.tf line 116, in resource "aws_lambda_function" "data_retrieval":
│ 116: resource "aws_lambda_function" "data_retrieval" {

│ The plugin encountered an error, and failed to respond to the
│ plugin.(*GRPCProvider).ApplyResourceChange call. The plugin logs may
│ contain more details.

Stack trace from the terraform-provider-aws_v4.61.0_x5 plugin:
panic: interface conversion: interface {} is string, not []interface {}

Relevant Error/Panic Output Snippet

Stack trace from the terraform-provider-aws_v4.61.0_x5 plugin:
panic: interface conversion: interface {} is string, not []interface {}
goroutine 32 [running]:
github.com/hashicorp/terraform-provider-aws/internal/service/rds.resourceClusterUpdate({0xe8838a0?, 0xc005a64810}, 0xc003051700, {0xd384cc0?, 0xc00045cc00})
	github.com/hashicorp/terraform-provider-aws/internal/service/rds/cluster.go:1282 +0x37b4
github.com/hashicorp/terraform-provider-aws/internal/provider.interceptedHandler[...].func1(0x0?, {0xd384cc0?, 0xc00045cc00?})
	github.com/hashicorp/terraform-provider-aws/internal/provider/intercept.go:94 +0x175
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).update(0xe8838a0?, {0xe8838a0?, 0xc00537b650?}, 0xd?, {0xd384cc0?, 0xc00045cc00?})
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:736 +0x87
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0xc0016922a0, {0xe8838a0, 0xc00537b650}, 0xc00531d6c0, 0xc003051580, {0xd384cc0, 0xc00045cc00})
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:847 +0x83a
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0xc00174fbc0, {0xe8838a0?, 0xc00537b530?}, 0xc0033898b0)
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/grpc_provider.go:1021 +0xe8d
github.com/hashicorp/terraform-plugin-mux/tf5muxserver.muxServer.ApplyResourceChange({0xc003158150, 0xc0031581b0, {0xc001be86e0, 0x2, 0x2}, {0x0, 0x0, 0x0}, {0x0, 0x0, ...}, ...}, ...)
	github.com/hashicorp/[email protected]/tf5muxserver/mux_server_ApplyResourceChange.go:27 +0x102
github.com/hashicorp/terraform-plugin-go/tfprotov5/tf5server.(*server).ApplyResourceChange(0xc0024fdd60, {0xe8838a0?, 0xc00537a810?}, 0xc005229340)
	github.com/hashicorp/[email protected]/tfprotov5/tf5server/server.go:818 +0x574
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0xd0899e0?, 0xc0024fdd60}, {0xe8838a0, 0xc00537a810}, 0xc0052292d0, 0x0)
	github.com/hashicorp/[email protected]/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:385 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0xc00082a000, {0xe892fa0, 0xc00496b520}, 0xc005379680, 0xc002ca2d20, 0x150d5e00, 0x0)
	google.golang.org/[email protected]/server.go:1336 +0xd23
google.golang.org/grpc.(*Server).handleStream(0xc00082a000, {0xe892fa0, 0xc00496b520}, 0xc005379680, 0x0)
	google.golang.org/[email protected]/server.go:1704 +0xa2f
google.golang.org/grpc.(*Server).serveStreams.func1.2()
	google.golang.org/[email protected]/server.go:965 +0x98
created by google.golang.org/grpc.(*Server).serveStreams.func1
	google.golang.org/[email protected]/server.go:963 +0x28a
Error: The terraform-provider-aws_v4.61.0_x5 plugin crashed!
This is always indicative of a bug within the plugin. It would be immensely
helpful if you could report the crash with the plugin's maintainers so that it
can be fixed. The output above should help diagnose the issue.

Terraform Configuration Files

Not permitted to share, sorry.

Steps to Reproduce

It started with upgrading to v4.61. Doesn't seem to be resource specific.

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

No response

Would you like to implement a fix?

None

@bendotexe bendotexe added bug Addresses a defect in current functionality. needs-triage Waiting for first response or review from a maintainer. labels Mar 31, 2023
@github-actions
Copy link

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.

@github-actions github-actions bot added crash Results from or addresses a Terraform crash or kernel panic. service/lambda Issues and PRs that pertain to the lambda service. service/rds Issues and PRs that pertain to the rds service. labels Mar 31, 2023
@ewbankkit ewbankkit removed service/lambda Issues and PRs that pertain to the lambda service. needs-triage Waiting for first response or review from a maintainer. labels Mar 31, 2023
@ewbankkit
Copy link
Contributor

ewbankkit commented Mar 31, 2023

if d.HasChange("master_password") {
if v, ok := d.GetOk("master_password"); ok && len(v.([]interface{})) > 0 && v.([]interface{}) != nil {
input.MasterUserPassword = aws.String(v.(string))
}
}

Relates #28848.

@github-actions
Copy link

github-actions bot commented May 1, 2023

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 May 1, 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. regression Pertains to a degraded workflow resulting from an upstream patch or internal enhancement. service/rds Issues and PRs that pertain to the rds service.
Projects
None yet
2 participants