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

data.azurerm_managed_disk: add missing create_option property #2597

Merged
merged 2 commits into from
Jan 4, 2019

Conversation

katbyte
Copy link
Collaborator

@katbyte katbyte commented Jan 4, 2019

fixes

Test ended in panic.

------- Stdout: -------
=== RUN   TestAccDataSourceAzureRMManagedDisk_basic
=== PAUSE TestAccDataSourceAzureRMManagedDisk_basic
=== CONT  TestAccDataSourceAzureRMManagedDisk_basic

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

goroutine 276 [running]:
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*ResourceData).Set(0xc420418af0, 0x240e22e, 0xd, 0x20b0e60, 0xc420012060, 0x4, 0x20b02e0)
	/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.flattenAzureRmManagedDiskCreationData(0xc420418af0, 0xc4205e8150)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/azurerm/resource_arm_managed_disk.go:297 +0x88
github.com/terraform-providers/terraform-provider-azurerm/azurerm.dataSourceArmManagedDiskRead(0xc420418af0, 0x23cc8e0, 0xc420990000, 0xc420418af0, 0x0)
	/opt/teamcity-agent/work/458e5e4800bd94f6/src/github.com/terraform-providers/terraform-provider-azurerm/azurerm/data_source_managed_disk.go:85 +0x615
github.com/terraform-providers/terraform-provider-azurerm/vendor/github.com/hashicorp/terraform/helper/schema.(*Resource).ReadDataApply(0xc4202a9f10, 0xc420cbe2c0, 0x23cc8e0, 0xc420990000, 0xc420293c00, 0xc420034901, 0xc42058a510)
	/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(0xc4204101c0, 0xc42032e4b0, 0xc420cbe2c0, 0x0, 0x30, 0xc420c12000)
	/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(0xc420bf9de0, 0x2741bc0, 0xc4209b4f70, 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, 0xc420bf9de0, 0x2741bc0, 0xc4209b4f70, 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(0xc420bf9e20, 0x2741bc0, 0xc4209b4f70, 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, 0xc420bf9e20, 0x2741bc0, 0xc4209b4f70, 0x212a320, 0x38afac2, 0x20b0e60, 0xc4203fc500)
	/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, 0xc420bf9e20, 0x2741bc0, 0xc4209b4f70, 0xc420bf9e20, 0x2708520, 0xc420bf9e20, 0xc420223be0)
	/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(0x2372760, 0xc4204a81c0, 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(0xc420394e00, 0x2372760, 0xc4204a81c0, 0xc4206af100)
	/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
@katbyte katbyte requested a review from a team January 4, 2019 03:19
@ghost ghost added the size/XS label Jan 4, 2019
@katbyte
Copy link
Collaborator Author

katbyte commented Jan 4, 2019

tests:

==> 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=TestAccDataSourceAzureRMManagedDisk_basic -timeout 180m -ldflags="-X=github.com/terraform-providers/terraform-provider-azurerm/version.ProviderVersion=acc"
=== RUN   TestAccDataSourceAzureRMManagedDisk_basic
=== PAUSE TestAccDataSourceAzureRMManagedDisk_basic
=== CONT  TestAccDataSourceAzureRMManagedDisk_basic
--- PASS: TestAccDataSourceAzureRMManagedDisk_basic (152.54s)
PASS
ok  	github.com/terraform-providers/terraform-provider-azurerm/azurerm	154.369s

@katbyte katbyte changed the title fix schema panic: azurerm_managed_disk data.azurerm_managed_disk: add missing create_option property 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 f34d424 into master Jan 4, 2019
@tombuildsstuff tombuildsstuff deleted the schema_panic/managed_disk branch January 4, 2019 15:30
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 👉 hashibot-feedback@hashicorp.com. 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.

None yet

2 participants