-
Notifications
You must be signed in to change notification settings - Fork 756
Open
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.version/5Categorizes issue or PR as related to version 5 of the provider.Categorizes issue or PR as related to version 5 of the provider.
Description
Confirmation
- This is a bug with an existing resource and is not a feature request or enhancement. Feature requests should be submitted with Cloudflare Support or your account team.
- I have searched the issue tracker and my issue isn't already found.
- I have replicated my issue using the latest version of the provider and it is still present.
Terraform and Cloudflare provider version
terraform -v
Terraform v1.13.4
on linux_amd64
+ provider registry.terraform.io/cloudflare/cloudflare v5.11.0Affected resource(s)
cloudflare_zone_setting
Only affects the ciphers setting_id.
Terraform configuration files
terraform {
required_providers {
cloudflare = {
source = "cloudflare/cloudflare"
version = "5.11.0"
}
}
}
provider "cloudflare" {}
resource "cloudflare_zone_setting" "ciphers" {
zone_id = "redacted"
setting_id = "ciphers"
value = []
}
import {
to = cloudflare_zone_setting.ciphers
id = "redacted/ciphers"
}Link to debug output
https://gist.github.com/simonhops/f26116feb3d1e6219ccaff219798ca74
Panic output
$ terraform plan
cloudflare_zone_setting.ciphers: Preparing import... [id=redacted/ciphers]
Planning failed. Terraform encountered an error while generating this plan.
╷
│ Error: Request cancelled
│
│ The plugin6.(*GRPCProvider).ImportResourceState request was cancelled.
╵
Stack trace from the terraform-provider-cloudflare_v5.11.0 plugin:
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x30 pc=0x1288075]
goroutine 11 [running]:
github.com/hashicorp/terraform-plugin-framework/types/basetypes.ListValue.ToTerraformValue({{0x89e2060, 0x0, 0x0}, {0x0, 0x0}, 0x2}, {0x4ff9918, 0xc0003e19b0})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/types/basetypes/list_value.go:208 +0x95
github.com/hashicorp/terraform-plugin-framework/types/basetypes.DynamicValue.ToTerraformValue({{0x50006d8?, 0xc0005b83c0?}, 0xa8?}, {0x4ff9918?, 0xc0003e19b0?})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/types/basetypes/dynamic_value.go:100 +0x5d
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromStruct({0x4ff9918, 0xc0003e19b0}, {0x50804f0, 0xc0005b83f0}, {0x4722480?, 0xc0001977a0?, 0x0?}, {{0x89e2060, 0x0, 0x0}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/struct.go:271 +0xd8c
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromValue({0x4ff9918, 0xc0003e19b0}, {0x50007b0, 0xc0005b83f0}, {0x4722480, 0xc0001977a0}, {{0x89e2060?, 0x3608cbc?, 0xc0002648c0?}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/outof.go:57 +0x6d8
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromPointer({0x4ff9918, 0xc0003e19b0}, {0x50007b0, 0xc0005b83f0}, {0x3d42220?, 0xc000255440?, 0x10?}, {{0x89e2060, 0x0, 0x0}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/pointer.go:138 +0x1eb
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromValue({0x4ff9918, 0xc0003e19b0}, {0x50007b0, 0xc0005b83f0}, {0x3d42220, 0xc000255440}, {{0x89e2060?, 0x0?, 0xc0005b8450?}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/outof.go:85 +0x425
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromPointer({0x4ff9918, 0xc0003e19b0}, {0x50007b0, 0xc0005b83f0}, {0x37e89c0?, 0xc000426738?, 0x0?}, {{0x89e2060, 0x0, 0x0}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/pointer.go:138 +0x1eb
github.com/hashicorp/terraform-plugin-framework/internal/reflect.FromValue({0x4ff9918, 0xc0003e19b0}, {0x50007b0, 0xc0005b83f0}, {0x37e89c0, 0xc000426738}, {{0x89e2060?, 0x0?, 0x0?}})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/reflect/outof.go:85 +0x425
github.com/hashicorp/terraform-plugin-framework/internal/fwschemadata.(*Data).Set(0xc000512ed0, {0x4ff9918, 0xc0003e19b0}, {0x37e89c0, 0xc000426738})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/fwschemadata/data_set.go:18 +0x8e
github.com/hashicorp/terraform-plugin-framework/tfsdk.(*State).Set(0xc00045f338, {0x4ff9918?, 0xc0003e19b0?}, {0x37e89c0?, 0xc000426738?})
github.com/hashicorp/terraform-plugin-framework@v1.15.0/tfsdk/state.go:64 +0x135
github.com/cloudflare/terraform-provider-cloudflare/internal/services/zone_setting.(*ZoneSettingResource).ImportState(0xc000426718, {0x4ff9918, 0xc0003e19b0}, {{0xc000270090?, 0x49cb854?}, 0x0?, {0x0?}}, 0xc00045f320)
github.com/cloudflare/terraform-provider-cloudflare/internal/services/zone_setting/resource.go:238 +0x785
github.com/hashicorp/terraform-plugin-framework/internal/fwserver.(*Server).ImportResourceState(0xc00012d408, {0x4ff9918, 0xc0003e19b0}, 0xc000269d00, 0xc0005135c0)
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/fwserver/server_importresourcestate.go:174 +0xa7b
github.com/hashicorp/terraform-plugin-framework/internal/proto6server.(*Server).ImportResourceState(0xc00012d408, {0x4ff9918?, 0xc0003e18c0?}, 0xc0003e1860)
github.com/hashicorp/terraform-plugin-framework@v1.15.0/internal/proto6server/server_importresourcestate.go:55 +0x3a6
github.com/hashicorp/terraform-plugin-go/tfprotov6/tf6server.(*server).ImportResourceState(0xc0002d2a00, {0x4ff9918?, 0xc0003e0a20?}, 0xc00045f0e0)
github.com/hashicorp/terraform-plugin-go@v0.28.0/tfprotov6/tf6server/server.go:972 +0x191
github.com/hashicorp/terraform-plugin-go/tfprotov6/internal/tfplugin6._Provider_ImportResourceState_Handler({0x48f5e80, 0xc0002d2a00}, {0x4ff9918, 0xc0003e0a20}, 0xc000422e80, 0x0)
github.com/hashicorp/terraform-plugin-go@v0.28.0/tfprotov6/internal/tfplugin6/tfplugin6_grpc.pb.go:705 +0x1a6
google.golang.org/grpc.(*Server).processUnaryRPC(0xc0001e0200, {0x4ff9918, 0xc0003e08d0}, 0xc00045f080, 0xc0003e09f0, 0x89b1900, 0x0)
google.golang.org/grpc@v1.72.1/server.go:1405 +0x103b
google.golang.org/grpc.(*Server).handleStream(0xc0001e0200, {0x4ffa2f0, 0xc000470000}, 0xc00045f080)
google.golang.org/grpc@v1.72.1/server.go:1815 +0xbaa
google.golang.org/grpc.(*Server).serveStreams.func2.1()
google.golang.org/grpc@v1.72.1/server.go:1035 +0x7f
created by google.golang.org/grpc.(*Server).serveStreams.func2 in goroutine 23
google.golang.org/grpc@v1.72.1/server.go:1046 +0x125
Error: The terraform-provider-cloudflare_v5.11.0 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.Expected output
The cloudflare_zone_setting with the setting_id ciphers is imported.
Actual output
Terraform fails with Stack trace.
Steps to reproduce
- export CLOUDFLARE_API_TOKEN="redacted"
- terraform init
- terraform plan
Additional factoids
No response
References
No response
Metadata
Metadata
Assignees
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.version/5Categorizes issue or PR as related to version 5 of the provider.Categorizes issue or PR as related to version 5 of the provider.