You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Create Datadog usersresource"datadog_user""users" {
# `source` comes from an external filefor_each=local.source.usersname=each.value.nameemail=each.value.email
}
Relevant debug or panic output
Stack trace from the terraform-provider-datadog_v3.36.1 plugin:
panic: runtime error: index out of range [0] with length 0
Error: The terraform-provider-datadog_v3.36.1 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.
Thanks for the report! I put up #2302 to ensure we don't panic when no results are found. However, as a followup, is it possible you are creating multiple users using the same email?
Datadog Terraform Provider Version
3.36.1
Terraform Version
1.7.4
What resources or data sources are affected?
datadog_user
Terraform Configuration Files
Relevant debug or panic output
Stack trace from the terraform-provider-datadog_v3.36.1 plugin:
panic: runtime error: index out of range [0] with length 0
goroutine 42 [running]:
github.com/terraform-providers/terraform-provider-datadog/datadog.resourceDatadogUserCreate({0x1b88080?, 0xc000a39aa0?}, 0x0?, {0x15154e0?, 0xc000a4a1e0})
github.com/terraform-providers/terraform-provider-datadog/datadog/resource_datadog_user.go:198 +0xdbb
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).create(0xc000315340, {0x1b88080, 0xc000a39aa0}, 0xd?, {0x15154e0, 0xc000a4a1e0})
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:733 +0x12e
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0xc000315340, {0x1b88080, 0xc000a39aa0}, 0xc000ad6000, 0xc00041aa00, {0x15154e0, 0xc000a4a1e0})
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:864 +0xa7e
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0xc000352738, {0x1b88080?, 0xc000a39950?}, 0xc000897860)
github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/grpc_provider.go:1024 +0xe8d
github.com/hashicorp/terraform-plugin-mux/tf5muxserver.muxServer.ApplyResourceChange({0xc00023bdd0, 0xc00023be30, {0xc000794d60, 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(0xc000748460, {0x1b88080?, 0xc000a4b440?}, 0xc0000c62a0)
github.com/hashicorp/[email protected]/tfprotov5/tf5server/server.go:821 +0x574
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0x182e020?, 0xc000748460}, {0x1b88080, 0xc000a4b440}, 0xc0000c6230, 0x0)
github.com/hashicorp/[email protected]/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:422 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0xc0004521e0, {0x1b8d960, 0xc000706d00}, 0xc000334fc0, 0xc00078de30, 0x28d2d00, 0x0)
google.golang.org/[email protected]/server.go:1335 +0xdf3
google.golang.org/grpc.(*Server).handleStream(0xc0004521e0, {0x1b8d960, 0xc000706d00}, 0xc000334fc0, 0x0)
google.golang.org/[email protected]/server.go:1712 +0xa36
google.golang.org/grpc.(*Server).serveStreams.func1.1()
google.golang.org/[email protected]/server.go:947 +0xca
created by google.golang.org/grpc.(*Server).serveStreams.func1
google.golang.org/[email protected]/server.go:958 +0x15c
Error: The terraform-provider-datadog_v3.36.1 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.
Operation failed: failed running terraform apply (exit 1)�
Expected Behavior
Plugin shouldn't crash
Actual Behavior
Plugin crashed
Steps to Reproduce
terraform apply
Important Factoids
No response
References
No response
The text was updated successfully, but these errors were encountered: