I have a terraform project to manage the codefresh pipeline. It was working fine with provide version 0.0.19.
With version 0.0.20, I could see there is a feature to enable notification in the pipeline using terraform. So I have upgraded to plugin to 0.0.20. I have added below piece of code to enable notification in my pipeline under trigger block.
2021-11-03T20:02:22.810+1100 [ERROR] plugin.(*GRPCProvider).ApplyResourceChange: error="rpc error: code = Unavailable desc = transport is closing"
╷
│ Error: Plugin did not respond
│
│ with codefresh_pipeline.pipeline["bff"],
│ on pipeline.tf line 28, in resource "codefresh_pipeline" "pipeline":
│ 28: resource "codefresh_pipeline" "pipeline" {
│
│ 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-codefresh_v0.0.20 plugin:
panic: interface conversion: interface {} is bool, not string
goroutine 98 [running]:
github.com/codefresh-io/terraform-provider-codefresh/codefresh.mapResourceToPipeline(0xc000114180, 0xc000424000)
/codefresh/volume/terraform-provider-codefresh/codefresh/resource_pipeline.go:696 +0x2f8f
github.com/codefresh-io/terraform-provider-codefresh/codefresh.resourcePipelineUpdate(0xc000114180, 0x185af60, 0xc0002340c0, 0x0, 0xffffffffffffffff)
/codefresh/volume/terraform-provider-codefresh/codefresh/resource_pipeline.go:405 +0x5e
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).update(0xc0002cefd0, 0x19891a0, 0xc0006b8280, 0xc000114180, 0x185af60, 0xc0002340c0, 0x0, 0x0, 0x0)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:293 +0x88
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0xc0002cefd0, 0x19891a0, 0xc0006b8280, 0xc000212150, 0xc000357c80, 0x185af60, 0xc0002340c0, 0x0, 0x0, 0x0, ...)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:395 +0x392
github.com/hashicorp/terraform-plugin-sdk/v2/internal/helper/plugin.(*GRPCProviderServer).ApplyResourceChange(0xc000284200, 0x19891a0, 0xc0006b8280, 0xc000212000, 0xc000284200, 0xc000284210, 0x1896ce0)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/internal/helper/plugin/grpc_provider.go:952 +0x8b2
github.com/hashicorp/terraform-plugin-sdk/v2/internal/tfplugin5._Provider_ApplyResourceChange_Handler.func1(0x19891a0, 0xc0006b8280, 0x18273e0, 0xc000212000, 0xc0006b8280, 0x17ac5c0, 0xc00008e401, 0xc000794620)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/internal/tfplugin5/tfplugin5.pb.go:3312 +0x86
github.com/hashicorp/terraform-plugin-sdk/v2/plugin.Serve.func3.1(0x1989260, 0xc00064e8a0, 0x18273e0, 0xc000212000, 0xc000794600, 0xc000794620, 0xc00070eb78, 0x108de68, 0x17ff360, 0xc00064e8a0)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/plugin/serve.go:76 +0x87
github.com/hashicorp/terraform-plugin-sdk/v2/internal/tfplugin5._Provider_ApplyResourceChange_Handler(0x18354c0, 0xc000284200, 0x1989260, 0xc00064e8a0, 0xc00008e4e0, 0xc000284820, 0x1989260, 0xc00064e8a0, 0xc00014e600, 0x123f)
/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/[email protected]/internal/tfplugin5/tfplugin5.pb.go:3314 +0x14b
google.golang.org/grpc.(*Server).processUnaryRPC(0xc000582900, 0x198ffe0, 0xc000583800, 0xc00081a000, 0xc000194de0, 0x1e8d080, 0x0, 0x0, 0x0)
/go/pkg/mod/google.golang.org/[email protected]/server.go:1024 +0x501
google.golang.org/grpc.(*Server).handleStream(0xc000582900, 0x198ffe0, 0xc000583800, 0xc00081a000, 0x0)
/go/pkg/mod/google.golang.org/[email protected]/server.go:1313 +0xd3d
google.golang.org/grpc.(*Server).serveStreams.func1.1(0xc00028e1d0, 0xc000582900, 0x198ffe0, 0xc000583800, 0xc00081a000)
/go/pkg/mod/google.golang.org/[email protected]/server.go:722 +0xa1
created by google.golang.org/grpc.(*Server).serveStreams.func1
/go/pkg/mod/google.golang.org/[email protected]/server.go:720 +0xa1
Error: The terraform-provider-codefresh_v0.0.20 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.