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

panic: on invalid depends_on reference root #21590

Closed
ghost opened this issue Jun 4, 2019 · 1 comment
Closed

panic: on invalid depends_on reference root #21590

ghost opened this issue Jun 4, 2019 · 1 comment
Labels

Comments

@ghost
Copy link

@ghost ghost commented Jun 4, 2019

Terraform Version

Terraform v0.12.0

Terraform Configuration Files

resource "null_resource" "one" {
}

resource "null_resource" "two" {
  depends_on = ["crash"]
}

Debug Output

https://gist.github.com/tinocode/74f4d413fb04b20b20055685574f6da3

Crash Output

https://gist.github.com/tinocode/56d0916eabdd77bad638cf22f81923a0

Expected Behavior

Terraform reports an error about the unknown reference:

unix% ~/Downloads/terraform-0.11.14 plan

Error: null_resource.two: resource depends on non-existent resource 'crash'

Actual Behavior

Terraform crashed in a Go panic.

Steps to Reproduce

cat > main.tf <<EOF
resource "null_resource" "one" {
}

resource "null_resource" "two" {
  depends_on = ["crash"]
}
EOF

terraform init
terraform plan

Additional Context

This actually came to light when I mistyped a depends_on reference as "null_resourceone" instead of "null_resource.one".

References

#21589

@hashibot

This comment has been minimized.

Copy link

@hashibot hashibot bot commented Jul 25, 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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@hashibot hashibot bot locked and limited conversation to collaborators Jul 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
2 participants
You can’t perform that action at this time.