-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
Running an empty destroy with an interpolated output fails #17691
Comments
Hi @tomelliff, Thanks for filing the issue! This is tangentially related to #17425, and I plan on taking care of them at the same time. |
Same issue here. When we rerun destroy to properly clean up all remaining resources, terraform now fails with output vars not finding their references. |
I am having the same issue. v0.11.6 This makes kitchen-terraform difficult as |
Is there any fix for this I am facing the same issue in v0.11.7 though I am facing this only for RDS and ELB. |
facing the same issue on |
I'm encountering the same issue with terraform 0.11.7. In my case, it appears related to using local variables in a module. Here's a simple example that reproduces it: main.tf
module foo/main.tf
Running terraform destroy on empty state:
However in my module if I remove the Working foo/main.tf
|
Hi @russellcardullo! Sorry for that weird error. Despite the similar symptoms, I expect (due to it being with local values rather than outputs) this is a different bug that'll need it's own fix. It'd be awesome if you could open a new top-level issue for it and complete the issue template (the content in your comment there is a great start!) and then that'll put it on our radar to test as part of preparing the next major release, which already contains some significant changes to how configuration expressions are resolved internally. Thanks! |
I'm fairly certain that this is a similar cause, as outputs and locals are handled in the same way overall. Issue #18026 is what I was going to reference after 0.12 drops and I can go back and clean up the output/locals edge cases in the destroy graphs. |
Thanks @apparentlymart and @jbardin! Let me know if you still need a new top level issue or need me to add information to #18026. Anything else I can provide happy to do so. Thanks again! |
Still having this issue in 0.11.11_linux_amd64 :( Destroy complete! Resources: 0 destroyed. |
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. |
Running an empty destroy with an interpolated output fails without setting
TF_WARN_OUTPUT_ERRORS
:Terraform Version
Terraform Configuration Files
Expected Behavior
Nothing to happen, it's an empty state file so a destroy should do nothing.
Actual Behavior
Steps to Reproduce
terraform init
terraform destroy
Additional Context
Terraform-Kitchen runs a destroy at the start of a test run to make sure that it's running from a clean state (use
verify
just to rerun the tests alone) so this gets triggered then.References
Looked around the issue tracker because I thought this would be covered elsewhere but doesn't appear to be. #17655 and #17425 seem to be different issues and my slightly related, previously raised issue at #17641 is also different to this exact issue.
The text was updated successfully, but these errors were encountered: