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

Error: Plugin did not respond #579

Closed
CraigCraig-jpeg opened this issue Oct 20, 2022 · 5 comments
Closed

Error: Plugin did not respond #579

CraigCraig-jpeg opened this issue Oct 20, 2022 · 5 comments

Comments

@CraigCraig-jpeg
Copy link

CraigCraig-jpeg commented Oct 20, 2022

Hi there,

Thank you for opening an issue. Please note that we try to keep the Terraform issue tracker reserved for bug reports and feature requests. For general usage questions, please see: https://www.terraform.io/community.html.

Terraform Version

1.0.7 and latest

Affected Resource(s)

Please list the resources as a list, for example:

  • pagerduty_service
  • pagerduty_service_integration

If this issue appears to affect multiple resources, it may be an issue with Terraform's core, so please mention this.

Terraform Configuration Files

resource "pagerduty_service" "x_ops" {
  name                    = "x"
  escalation_policy       = pagerduty_escalation_policy.x.id
  alert_creation          = "create_alerts_and_incidents"
  acknowledgement_timeout = "null"
  alert_grouping_parameters {
    type = "time"
    config {
      timeout = 0
    }
  }
  incident_urgency_rule {
    type    = "constant"
    urgency = "severity_based"
  }
}

resource "pagerduty_service_integration" "x_ops" {
  name              = "email"
  service           = pagerduty_service.x_ops.id
  type              = "generic_email_inbound_integration"
  integration_email = "x_ops${local.default_mail_domain}"
}

Debug Output

Please provider a link to a GitHub Gist containing the complete debug output: https://www.terraform.io/docs/internals/debugging.html. Please do NOT paste the debug output in the issue; just paste a link to the Gist.

Panic Output

pagerduty_service.xxxxxxx: Creating...

│ Error: Plugin did not respond

│ 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-pagerduty_v2.6.3 plugin:

panic: interface conversion: interface {} is []interface {}, not map[string]interface {}

goroutine 2787 [running]:
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.expandAlertGroupingParameters({0xc99c00, 0xc0004f5f50})
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:578 +0x354
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.buildServiceStruct(0xc000093a00)
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:350 +0x3ff
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.resourcePagerDutyServiceCreate(0x0, {0xcf36a0, 0xc000093a00})
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:434 +0x65
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).create(0xce6fc0, {0x10275b8, 0xc00008ae40}, 0x2, {0xcf36a0, 0xc000093a00})
github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/resource.go:329 +0x178
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0xc0003b2b60, {0x10275b8, 0xc00008ae40}, 0xc00070b520, 0xc00054aa80, {0xcf36a0, 0xc000093a00})
github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/resource.go:467 +0x871
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0xc00012f4e8, {0x10275b8, 0xc00008ae40}, 0xc00032caf0)
github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/grpc_provider.go:977 +0xd8a
github.com/hashicorp/terraform-plugin-go/tfprotov5/tf5server.(*server).ApplyResourceChange(0xc0001ab480, {0x1027660, 0xc0003ef7a0}, 0xc0002cc540)
github.com/hashicorp/terraform-plugin-go@v0.5.0/tfprotov5/tf5server/server.go:603 +0x30e
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0xdb4900, 0xc0001ab480}, {0x1027660, 0xc0003ef7a0}, 0xc000501b00, 0x0)
github.com/hashicorp/terraform-plugin-go@v0.5.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:380 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0xc000230e00, {0x10381e8, 0xc0001a6a80}, 0xc000094d00, 0xc0003dde30, 0x1605620, 0x0)
google.golang.org/grpc@v1.33.2/server.go:1210 +0xc8f
google.golang.org/grpc.(*Server).handleStream(0xc000230e00, {0x10381e8, 0xc0001a6a80}, 0xc000094d00, 0x0)
google.golang.org/grpc@v1.33.2/server.go:1533 +0xa2a
google.golang.org/grpc.(*Server).serveStreams.func1.2()
google.golang.org/grpc@v1.33.2/server.go:871 +0x98
created by google.golang.org/grpc.(*Server).serveStreams.func1
google.golang.org/grpc@v1.33.2/server.go:869 +0x294
Error: The terraform-provider-pagerduty_v2.6.3 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 Behavior

terrafrom apply

Actual Behavior

failing plugin

Steps to Reproduce

Please list the steps required to reproduce the issue, for example:
terraform init
terraform plan
terraform apply

Important Factoids

none

References

The plugin encountered an error, and failed to respond to the plugin.(*GRPCProvider).ApplyResourceChange call. · Issue #447 · PagerDuty/terraform-provider-pagerduty · GitHub
Safer HTTP client initialization and usage. by dobs · Pull Request #458 · PagerDuty/terraform-provider-pagerduty · GitHub

@CraigCraig-jpeg
Copy link
Author

Please dont hesitate to ask for code

@CraigCraig-jpeg
Copy link
Author

we have been having this problem since 13 october. Fails on the service aspect of things

@CraigCraig-jpeg
Copy link
Author

For anyone wondering, the latest changes in 2.6.3 has broken pager duty plugin. Revert to 2.6.2 to fix. checking issue now but seems to be with the latest changes.

@pdecat
Copy link
Contributor

pdecat commented Nov 2, 2022

I've reproduced this error with v2.6.3 of the PagerDuty terraform provider:

Stack trace from the terraform-provider-pagerduty_v2.6.3 plugin:

panic: interface conversion: interface {} is []interface {}, not map[string]interface {}

goroutine 245 [running]:
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.expandAlertGroupingParameters({0xc99c00, 0xc000132d98})
        github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:578 +0x354
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.buildServiceStruct(0xc000014c00)
        github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:350 +0x3ff
github.com/terraform-providers/terraform-provider-pagerduty/pagerduty.resourcePagerDutyServiceUpdate(0xc000a34200, {0xcf36a0, 0xc000014c00})
        github.com/terraform-providers/terraform-provider-pagerduty/pagerduty/resource_pagerduty_service.go:462 +0x58
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).update(0xce6fc0, {0x10275b8, 0xc00011dbc0}, 0x24, {0xcf36a0, 0xc000014c00})
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/resource.go:363 +0x178
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0xc0004409a0, {0x10275b8, 0xc00011dbc0}, 0xc0004a9ee0, 0xc000369f00, {0xcf36a0, 0xc000014c00})
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/resource.go:475 +0x6ba
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0xc0002928d0, {0x10275b8, 0xc00011dbc0}, 0xc000a63680)
        github.com/hashicorp/terraform-plugin-sdk/v2@v2.10.1/helper/schema/grpc_provider.go:977 +0xd8a
github.com/hashicorp/terraform-plugin-go/tfprotov5/tf5server.(*server).ApplyResourceChange(0xc000295080, {0x1027660, 0xc000899b60}, 0xc0007900e0)
        github.com/hashicorp/terraform-plugin-go@v0.5.0/tfprotov5/tf5server/server.go:603 +0x30e
github.com/hashicorp/terraform-plugin-go/tfprotov5/internal/tfplugin5._Provider_ApplyResourceChange_Handler({0xdb4900, 0xc000295080}, {0x1027660, 0xc000899b60}, 0xc000565e60, 0x0)
        github.com/hashicorp/terraform-plugin-go@v0.5.0/tfprotov5/internal/tfplugin5/tfplugin5_grpc.pb.go:380 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0xc0002b08c0, {0x10381e8, 0xc000428600}, 0xc000834300, 0xc0004921e0, 0x1605620, 0x0)
        google.golang.org/grpc@v1.33.2/server.go:1210 +0xc8f
google.golang.org/grpc.(*Server).handleStream(0xc0002b08c0, {0x10381e8, 0xc000428600}, 0xc000834300, 0x0)
        google.golang.org/grpc@v1.33.2/server.go:1533 +0xa2a
google.golang.org/grpc.(*Server).serveStreams.func1.2()
        google.golang.org/grpc@v1.33.2/server.go:871 +0x98
created by google.golang.org/grpc.(*Server).serveStreams.func1
        google.golang.org/grpc@v1.33.2/server.go:869 +0x294

Error: The terraform-provider-pagerduty_v2.6.3 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.

Downgrading to v2.6.2 of the provider does work-around the issue.

@pdecat
Copy link
Contributor

pdecat commented Nov 2, 2022

Hi @imjaroiswebdev, this seems to be caused by #570

Mind to re-open this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants