Some additional info. Sometimes it seems to work without any problems. Sometimes crash with a " runtime error: invalid memory address or nil pointer dereference" error.
But there is also another reason "concurrent map iteration and map write"
Stack trace from the terraform-provider-genesyscloud _v1.47.0.exe plugin:
fatal error: concurrent map iteration and map write
goroutine 18051 [running]:
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.postProcessHclBytes({0xc002488200?, 0x35?, 0x441?})
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -hcl_exporter.go:169 +0x11f
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.writeHCLToFile({0xc001d44bf8, 0x1, 0x22c8588?}, {0xc001b6c440, 0x35})
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -hcl_exporter.go:186 +0xf1
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.(*HCLExporter).exportHCLConfig(0xc001d44fb8)
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -hcl_exporter.go:54 +0x2cb
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.(*GenesysCloudResourceExporter).generateOutputFiles(0xc001a3cb00)
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -genesyscloud_resource_exporter.go:469 +0x218
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.(*GenesysCloudResourceExporter).Export(0xc001a3cb00)
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -genesyscloud_resource_exporter.go:216 +0x85
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter.createTfExport({0x22d5ca0, 0xc0021dfbf0}, 0xc00080f380, {0x1a3e400, 0xc0005b4630})
terraform-provider-genesyscloud - / -genesyscloud- / -tfexporter- / -resource_genesyscloud_tf_export.go:159 +0x78
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2- / -helper- / -schema.(*Resource).create(0x22d5ca0?, {0x22d5ca0?, 0xc0021dfbf0?}, 0xd?, {0x1a3e400?, 0xc0005b4630?})
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2@v2.34.0- / -helper- / -schema- / -resource.go:801 +0x7a
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2- / -helper- / -schema.(*Resource).Apply(0xc0003eb500, {0x22d5ca0, 0xc0021dfbf0}, 0xc001adcd00, 0xc00080f200, {0x1a3e400, 0xc0005b4630})
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2@v2.34.0- / -helper- / -schema- / -resource.go:937 +0xa89
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2- / -helper- / -schema.(*GRPCProviderServer).ApplyResourceChange(0xc00050c5d0, {0x22d5ca0?, 0xc0021dfb30?}, 0xc00209fc70)
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2@v2.34.0- / -helper- / -schema- / -grpc_provider.go:1153 +0xd5c
github-com - / -hashicorp- / -terraform-plugin-go- / -tfprotov5- / -tf5server.(*server).ApplyResourceChange(0xc0002b72c0, {0x22d5ca0?, 0xc0021df0e0?}, 0xc000cf9f10)
github-com - / -hashicorp- / -terraform-plugin-go@v0.23.0- / -tfprotov5- / -tf5server- / -server.go:865 +0x3d0
github-com - / -hashicorp- / -terraform-plugin-go- / -tfprotov5- / -internal- / -tfplugin5._Provider_ApplyResourceChange_Handler({0x1cda3e0, 0xc0002b72c0}, {0x22d5ca0, 0xc0021df0e0}, 0xc00080ef80, 0x0)
github-com - / -hashicorp- / -terraform-plugin-go@v0.23.0- / -tfprotov5- / -internal- / -tfplugin5- / -tfplugin5_grpc.pb.go:518 +0x1a6
google.golang.org- / -grpc.(*Server).processUnaryRPC(0xc0000f4000, {0x22d5ca0, 0xc0021df050}, {0x22dbd40, 0xc000002000}, 0xc0011119e0, 0xc00050bec0, 0x2cf79f8, 0x0)
google.golang.org- / -grpc@v1.63.2- / -server.go:1369 +0xdf8
google.golang.org- / -grpc.(*Server).handleStream(0xc0000f4000, {0x22dbd40, 0xc000002000}, 0xc0011119e0)
google.golang.org- / -grpc@v1.63.2- / -server.go:1780 +0xe8b
google.golang.org- / -grpc.(*Server).serveStreams.func2.1()
google.golang.org- / -grpc@v1.63.2- / -server.go:1019 +0x8b
created by google.golang.org- / -grpc.(*Server).serveStreams.func2 in goroutine 40
google.golang.org- / -grpc@v1.63.2- / -server.go:1030 +0x125
goroutine 1 [select, 1 minutes]:
github-com - / -hashicorp- / -go-plugin.Serve(0xc000356ba0)
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -server.go:503 +0x158b
github-com - / -hashicorp- / -terraform-plugin-go- / -tfprotov5- / -tf5server.Serve({0x1d7730e, 0x8}, 0xc0003e2760, {0x0, 0x0, 0x0})
github-com - / -hashicorp- / -terraform-plugin-go@v0.23.0- / -tfprotov5- / -tf5server- / -server.go:316 +0xbe5
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2- / -plugin.tf5serverServe(0xc000356b40)
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2@v2.34.0- / -plugin- / -serve.go:188 +0x4b9
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2- / -plugin.Serve(0xc000356b40)
github-com - / -hashicorp- / -terraform-plugin-sdk- / -v2@v2.34.0- / -plugin- / -serve.go:128 +0x28e
main.main()
terraform-provider-genesyscloud - / -main.go:159 +0x20b
goroutine 8 [select, 1 minutes]:
github-com - / -hashicorp- / -go-plugin.(*gRPCBrokerServer).Recv(0x0?)
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_broker.go:128 +0x65
github-com - / -hashicorp- / -go-plugin.(*GRPCBroker).Run(0xc00036bad0)
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_broker.go:582 +0x4f
created by github-com - / -hashicorp- / -go-plugin.(*GRPCServer).Init in goroutine 1
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_server.go:91 +0x57a
goroutine 9 [syscall, 1 minutes, locked to thread]:
syscall.SyscallN(0x0?, {0xc000169c50?, 0xc000169c88?, 0x9bd79b?})
runtime- / -syscall_windows.go:544 +0x107
syscall.Syscall6(0x9ab3a8?, 0x0?, 0x0?, 0x0?, 0x25bfd5d92c8?, 0x1000?, 0x1?, 0xc000169d40?)
runtime- / -syscall_windows.go:488 +0x4a
syscall.readFile(0x184, {0xc000520000?, 0x1000, 0x25bfd5d92c8?}, 0x0?, 0x800000?)
syscall- / -zsyscall_windows.go:1021 +0x8b
syscall.ReadFile(...)
syscall- / -syscall_windows.go:442
syscall.Read(0xc000127408?, {0xc000520000?, 0x9b705c?, 0x2da2280?})
syscall- / -syscall_windows.go:421 +0x2d
internal- / -poll.(*FD).Read(0xc000127408, {0xc000520000, 0x1000, 0x1000})
internal- / -poll- / -fd_windows.go:422 +0x1c5
os.(*File).read(...)
os- / -file_posix.go:29
os.(*File).Read(0xc0001120b8, {0xc000520000?, 0x400?, 0x1abb640?})
os- / -file.go:118 +0x52
bufio.(*Reader).Read(0xc000169f20, {0xc00011a800, 0x400, 0x0?})
bufio- / -bufio.go:241 +0x197
github-com - / -hashicorp- / -go-plugin.copyChan({0x22e07f8, 0xc0002b7040}, 0xc000107860, {0x22cd5c0, 0xc0001120b8?})
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_stdio.go:184 +0x1c5
created by github-com - / -hashicorp- / -go-plugin.newGRPCStdioServer in goroutine 1
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_stdio.go:40 +0xcc
goroutine 10 [syscall, 1 minutes, locked to thread]:
syscall.SyscallN(0x0?, {0xc000517c50?, 0xc000517c88?, 0x9bd79b?})
runtime- / -syscall_windows.go:544 +0x107
syscall.Syscall6(0x9ab3a8?, 0x0?, 0x0?, 0x0?, 0x25bd82b0828?, 0x1000?, 0x1?, 0xc000517d40?)
runtime- / -syscall_windows.go:488 +0x4a
syscall.readFile(0x188, {0xc0005b2000?, 0x1000, 0x25bfd429888?}, 0x0?, 0x800000?)
syscall- / -zsyscall_windows.go:1021 +0x8b
syscall.ReadFile(...)
syscall- / -syscall_windows.go:442
syscall.Read(0xc000127908?, {0xc0005b2000?, 0x9b705c?, 0x2da2280?})
syscall- / -syscall_windows.go:421 +0x2d
internal- / -poll.(*FD).Read(0xc000127908, {0xc0005b2000, 0x1000, 0x1000})
internal- / -poll- / -fd_windows.go:422 +0x1c5
os.(*File).read(...)
os- / -file_posix.go:29
os.(*File).Read(0xc0001120c8, {0xc0005b2000?, 0x400?, 0x1abb640?})
os- / -file.go:118 +0x52
bufio.(*Reader).Read(0xc000517f20, {0xc00047c400, 0x400, 0x0?})
bufio- / -bufio.go:241 +0x197
github-com - / -hashicorp- / -go-plugin.copyChan({0x22e07f8, 0xc0002b7040}, 0xc0001078c0, {0x22cd5c0, 0xc0001120c8?})
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_stdio.go:184 +0x1c5
created by github-com - / -hashicorp- / -go-plugin.newGRPCStdioServer in goroutine 1
github-com - / -hashicorp- / -go-plugin@v1.6.0- / -grpc_stdio.go:41 +0x13e
Error: The terraform-provider-genesyscloud _v1.47.0.exe 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.
don't hesitate to reach out for more info.
Kr,
Kevin