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

fix scheme panic: azurerm_storage_account datasource #2595

Merged
merged 1 commit into from
Jan 4, 2019

Conversation

katbyte
Copy link
Collaborator

@katbyte katbyte commented Jan 4, 2019

fix schema panic:

Test ended in panic.

------- Stdout: -------
=== RUN   TestAccDataSourceAzureRMStorageAccount_basic
=== PAUSE TestAccDataSourceAzureRMStorageAccount_basic
=== CONT  TestAccDataSourceAzureRMStorageAccount_basic

------- Stderr: -------
panic: Invalid address to set: []string{"account_type"}

goroutine 675 [running]:
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*ResourceData).Set(0xc420215c00, 0x240c883, 0xc, 0x20ae460, 0xc42054d480, 0x0, 0x0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema/resource_data.go:191 +0x237
github.com/terraform-providers/terraform-provider-azurerm/azurerm.dataSourceArmStorageAccountRead(0xc420215c00, 0x23cc8e0, 0xc4206b6000, 0xc420215c00, 0x0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/azurerm/data_source_storage_account.go:197 +0x161d
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*Resource).ReadDataApply(0xc4202c90a0, 0xc4206fafa0, 0x23cc8e0, 0xc4206b6000, 0xc4202938b0, 0xc420e07501, 0xc4203131d0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema/resource.go:290 +0x88
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*Provider).ReadDataApply(0xc4203d21c0, 0xc420212320, 0xc4206fafa0, 0x0, 0x30, 0xc420c80000)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema/provider.go:426 +0x9a
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.(*EvalReadDataApply).Eval(0xc4206faa60, 0x2741bc0, 0xc420890680, 0x2, 0x2, 0x2402b44, 0x4)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/eval_read_data.go:122 +0xfe
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.EvalRaw(0x2708420, 0xc4206faa60, 0x2741bc0, 0xc420890680, 0x0, 0x0, 0x0, 0x0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/eval.go:53 +0x156
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.(*EvalSequence).Eval(0xc4206faaa0, 0x2741bc0, 0xc420890680, 0x2, 0x2, 0x2402b44, 0x4)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/eval_sequence.go:14 +0x7a
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.EvalRaw(0x2708520, 0xc4206faaa0, 0x2741bc0, 0xc420890680, 0x212a320, 0x38afac5, 0x20b0e60, 0xc4203b38f0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/eval.go:53 +0x156
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.Eval(0x2708520, 0xc4206faaa0, 0x2741bc0, 0xc420890680, 0xc4206faaa0, 0x2708520, 0xc4206faaa0, 0xc420860be0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/eval.go:34 +0x4d
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform.(*Graph).walk.func1(0x2352d40, 0xc420716870, 0x0, 0x0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/terraform/graph.go:126 +0xc26
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/dag.(*Walker).walkVertex(0xc420215110, 0x2352d40, 0xc420716870, 0xc420de0640)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/dag/walk.go:387 +0x3a0
created by github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/dag.(*Walker).Update
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/dag/walk.go:310 +0x1248

@katbyte katbyte added this to the 1.21.0 milestone Jan 4, 2019
@ghost ghost added the size/XS label Jan 4, 2019
@katbyte
Copy link
Collaborator Author

katbyte commented Jan 4, 2019

tests:

[18:53:44] kt@snowbook:~/hashi/..3../terraform-providers/terraform-provider-azurerm▸schema_panic/storage$ testazure TestAccDataSourceAzureRMStorageAccount_basic
==> Fixing source code with gofmt...
gofmt -s -w ./azurerm
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./azurerm -v -test.run=TestAccDataSourceAzureRMStorageAccount_basic -timeout 180m -ldflags="-X=github.com/terraform-providers/terraform-provider-azurerm/version.ProviderVersion=acc"
=== RUN   TestAccDataSourceAzureRMStorageAccount_basic
=== PAUSE TestAccDataSourceAzureRMStorageAccount_basic
=== CONT  TestAccDataSourceAzureRMStorageAccount_basic
--- PASS: TestAccDataSourceAzureRMStorageAccount_basic (125.97s)
PASS
ok  	github.com/terraform-providers/terraform-provider-azurerm/azurerm	127.864s

@katbyte katbyte changed the title scheme panic: azurerm_storage_account datasource fix scheme panic: azurerm_storage_account datasource Jan 4, 2019
Copy link
Contributor

@tombuildsstuff tombuildsstuff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@tombuildsstuff tombuildsstuff merged commit e9cb65c into master Jan 4, 2019
@tombuildsstuff tombuildsstuff deleted the schema_panic/storage branch January 4, 2019 15:39
tombuildsstuff added a commit that referenced this pull request Jan 4, 2019
@ghost
Copy link

ghost commented Mar 5, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants