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: The terraform-provider-snowflake_v0.80.0 plugin crashed #2283

Closed
jacobcbeaudin opened this issue Dec 20, 2023 · 5 comments
Closed

Error: The terraform-provider-snowflake_v0.80.0 plugin crashed #2283

jacobcbeaudin opened this issue Dec 20, 2023 · 5 comments
Assignees
Labels
bug Used to mark issues with provider's incorrect behavior

Comments

@jacobcbeaudin
Copy link
Contributor

jacobcbeaudin commented Dec 20, 2023

Terraform CLI and Provider Versions

Terraform CLI version: 1.6.1
Snowflake Provider Version: 0.80.0

Terraform Configuration

terraform {

  required_version = ">= 1.6.1"

  required_providers {
    snowflake = {
      source  = "Snowflake-Labs/snowflake"
      version = "0.80.0"
    }
  }
}

provider "snowflake" {
  account       = data.terraform_remote_state.snowflake_infrastructure.outputs.snowflake_account
  authenticator = "JWT"
}

provider "snowflake" {
  alias         = "account_admin"
  role          = "ACCOUNTADMIN"
  account       = data.terraform_remote_state.snowflake_infrastructure.outputs.snowflake_account
  authenticator = "JWT"
}

provider "snowflake" {
  alias         = "security_admin"
  role          = "SECURITYADMIN"
  account       = data.terraform_remote_state.snowflake_infrastructure.outputs.snowflake_account
  authenticator = "JWT"
}

provider "snowflake" {
  alias         = "sys_admin"
  role          = "SYSADMIN"
  account       = data.terraform_remote_state.snowflake_infrastructure.outputs.snowflake_account
  authenticator = "JWT"
}

Expected Behavior

create external tables in snowflake

Actual Behavior

╷
│ Error: Plugin did not respond
│
│ The plugin encountered an error, and failed to respond to the plugin6.(*GRPCProvider).ApplyResourceChange call. The plugin logs may contain more details.
╵

Stack trace from the terraform-provider-snowflake_v0.80.0 plugin:

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

goroutine 66 [running]:
github.com/Snowflake-Labs/terraform-provider-snowflake/pkg/resources.CreateExternalTable(0x0?, {0x10606ebc0?, 0x1400086a8f0?})
	github.com/Snowflake-Labs/terraform-provider-snowflake/pkg/resources/external_table.go:181 +0xb84
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).create(0x1060b2100?, {0x1060b2100?, 0x14000994de0?}, 0xd?, {0x10606ebc0?, 0x1400086a8f0?})
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:766 +0x134
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).Apply(0x14000d14460, {0x1060b2100, 0x14000994de0}, 0x14000638750, 0x1400099c280, {0x10606ebc0, 0x1400086a8f0})
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/resource.go:909 +0x8a0
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*GRPCProviderServer).ApplyResourceChange(0x14000c409a8, {0x1060b2100?, 0x14000994c00?}, 0x140009a6140)
	github.com/hashicorp/terraform-plugin-sdk/[email protected]/helper/schema/grpc_provider.go:1072 +0xb78
github.com/hashicorp/terraform-plugin-mux/tf5to6server.v5tov6Server.ApplyResourceChange({{0x1060c5920?, 0x14000c409a8?}}, {0x1060b2100, 0x14000994c00}, 0x0?)
	github.com/hashicorp/[email protected]/tf5to6server/tf5to6server.go:37 +0x58
github.com/hashicorp/terraform-plugin-mux/tf6muxserver.(*muxServer).ApplyResourceChange(0x1060b2058?, {0x1060b2100?, 0x140009948d0?}, 0x140009a60f0)
	github.com/hashicorp/[email protected]/tf6muxserver/mux_server_ApplyResourceChange.go:36 +0x188
github.com/hashicorp/terraform-plugin-go/tfprotov6/tf6server.(*server).ApplyResourceChange(0x14000bc6280, {0x1060b2100?, 0x14000994030?}, 0x1400099e000)
	github.com/hashicorp/[email protected]/tfprotov6/tf6server/server.go:857 +0x3bc
github.com/hashicorp/terraform-plugin-go/tfprotov6/internal/tfplugin6._Provider_ApplyResourceChange_Handler({0x106017200?, 0x14000bc6280}, {0x1060b2100, 0x14000994030}, 0x1400099c000, 0x0)
	github.com/hashicorp/[email protected]/tfprotov6/internal/tfplugin6/tfplugin6_grpc.pb.go:467 +0x170
google.golang.org/grpc.(*Server).processUnaryRPC(0x140001494a0, {0x1060b2100, 0x140010e8cf0}, {0x1060c1a20, 0x14000a8b040}, 0x14000a26000, 0x14000951410, 0x106d071b8, 0x0)
	google.golang.org/[email protected]/server.go:1343 +0xc6c
google.golang.org/grpc.(*Server).handleStream(0x140001494a0, {0x1060c1a20, 0x14000a8b040}, 0x14000a26000)
	google.golang.org/[email protected]/server.go:1737 +0x9f0
google.golang.org/grpc.(*Server).serveStreams.func1.1()
	google.golang.org/[email protected]/server.go:986 +0x88
created by google.golang.org/grpc.(*Server).serveStreams.func1
	google.golang.org/[email protected]/server.go:997 +0x174

Error: The terraform-provider-snowflake_v0.80.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.

Steps to Reproduce

  1. terraform apply

How much impact is this issue causing?

High

Logs

No response

Additional Information

No response

@jacobcbeaudin jacobcbeaudin added the bug Used to mark issues with provider's incorrect behavior label Dec 20, 2023
@sfc-gh-jcieslak
Copy link
Collaborator

Hey @jacobcbeaudin. Thanks for reporting the issue.

The fix should be really simple. I'll push a pr for the fix today or tomorrow and it should be a part of the next release.

@oemergenc
Copy link

@sfc-gh-jcieslak Wow, thanks for fixing it so fast. It seems like the tests in the build are failing?
When will there be a next release?

sfc-gh-asawicki pushed a commit that referenced this issue Dec 21, 2023
🤖 I have created a release *beep* *boop*
---


##
[0.82.0](v0.81.0...v0.82.0)
(2023-12-21)


### 🎉 **What's new:**

* add functions to sdk
([#2205](#2205))
([e542b67](e542b67))


### 🔧 **Misc**

* Add short scripts used to fetch all currently opened issues
([#2288](#2288))
([0b5ce4e](0b5ce4e))
* Bump dependencies and fix linter complaints
([#2300](#2300))
([124e862](124e862))


### 🐛 **Bug fixes:**

* Fix resource monitor alter validations in the SDK
([#2298](#2298))
([74d19d0](74d19d0))
* Fix email notification integration
([#2292](#2292))
([70edd3e](70edd3e))
* Fix for #2283 
([#2284](#2284))
([bbad5c6](bbad5c6))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: snowflake-release-please[bot] <105954990+snowflake-release-please[bot]@users.noreply.github.com>
@sfc-gh-jcieslak
Copy link
Collaborator

@oemergenc @jacobcbeaudin
It was released today as part of the 0.82.0 version. When you update please let me know if the issue has been fixed or just close the issue, Thanks.

@jacobcbeaudin
Copy link
Contributor Author

@oemergenc @jacobcbeaudin

It was released today as part of the 0.82.0 version. When you update please let me know if the issue has been fixed or just close the issue, Thanks.

0.82.0 fixed my issue. Thank you for the quick fix

@oemergenc
Copy link

@jacobcbeaudin @sfc-gh-jcieslak
Unfortunately the issue does not seem to be fixed. Please see my comments here:
#2293 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Used to mark issues with provider's incorrect behavior
Projects
None yet
Development

No branches or pull requests

3 participants