-
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
Terraform v0.13.0 Panic When Using Module Composition #25114
Comments
Thanks for reporting this, @adamhorden! Here's the isolated stack trace, for easier reference by someone working on this bug later:
I understand that this is a complicated configuration that's hard for you to reduce into a minimal reproducible example. As a compromise, if you could share some details about the heirarchy of modules that you have that might help to understand what we can see in the logs and the stack trace. One way to quickly get an easily-shareable summary of the modules would be to run |
@apparentlymart I am trying to produce a reproducible test case. I can make this fail across many of our projects. In fact non of our projects will run with a v0.13 release. I have attached a gist of init: https://gist.github.com/adamhorden/24e7f8b72a73ba2f08d0bbbb5f9471e7 I am still working on a reproducible test case. The best I could do is checkout all the modules, update the source link to these, sanitise any data, and tar it and then encrypt with the HashiCorp GPG key as a worst case if I fail at a reproducible test case 🤔 . Thanks again for all of the hard work that has gone into Terraform v0.13 😬 . EDIT: I was thinking you need to see the hierarchy while I work on a reproducible test case: I ran https://gist.github.com/adamhorden/b437a4f39e563ae6340b72eda52adaa4 This is only 10%, I had to commented out all the other modules for testing but the pattern getting to the panic is still the same. |
Thanks! I think I'm going to re-add our "waiting-response" label here because I think your smaller reproduction case is likely to be needed to fully understand this, but someone else on the team who is more familiar with the new module processing might 🤞 be able to offer an explanation based just on the stack trace, if we're lucky! 😄 |
I have a test case @apparentlymart 💥 🤓 . There is a README.md, same as my last report with a full steps taken to get a panic. One hierarchy down is full modules. This will always create the panic I am reporting. I am starting to think that Hope this test case helps. It is extensive as a test case. Sorry I could not cut it down any more. It was racking my head for half a day how to come up with a repeatable test case. |
Looks like I am seeing the same:
edit: added full crash log. |
Here's the closest I got to a minimal test case, https://github.com/ipmb/terraform-issue-25114 The VPC module here is a copy of https://github.com/terraform-aws-modules/terraform-aws-vpc/ with the version limitation removed to workaround terraform-aws-modules/terraform-aws-vpc#453 |
Team, We are experiencing the same/similar issue with one of our modules (using terraform version v0.13.0-beta1) Here is the full crash.log https://gist.github.com/ficofer/3350a93db889f2aa64b9c8b41a2590c4 This is the short output:
Adding more information here: This is the crash log when I run one of the inner modules called from the parent module that failed above. https://gist.github.com/ficofer/e0179331b4a904bdc833454f88219fa8 We discover that this module is the one failing calling other two submodules, moduleA and moduleB If I comment out moduleA and leave moduleB it works. If I left both of them together it fails, it's worth noting that the modules does not have any dependent variables in between each other. Great work team! |
First of all thanks for all the great work being done on 0.13 and thanks to the people in this thread giving diagnostic information. |
Also hitting a similar issue. I can provide additional crash logs if needed. |
@ipmb I have reproduced this using your reproduction case, which I copied into my own repo (https://github.com/danieldreier/terraform-issue-reproductions/tree/master/25114). Based on this, I think we have enough detail to work on this. Thank you @adamhorden @ipmb and everybody in this thread. I am so happy to have you all trying out this code, finding bugs, and figuring out reproduction cases. Thank you! |
Hi. I believe that the crash I am experiencing in my code is related to this bug report, because the panic message looks similar. This Bash command sequence:
triggers the following Terraform crash:
The complete The Terraform version is:
|
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. |
Terraform Version
Terraform Configuration Files
I have had to just add crash.log to this issue report. This is an interesting panic, as it seems to be that if I have greater than two modules called from a root module I cause this panic. I can always try and strip out internal configuration to produce a test case so I am hoping crash.log will help you debug this panic.
If required I could tar up the config but it is multiple modules all in multiple git repos so hoping the stack trace will suffice.
Crash Output
https://gist.github.com/adamhorden/9730f0415d5166844ee1a947d8486f81
panic: no expansion has been registered for module.he_aws_tf_mod_he_aws_tf_app_itf.module.he_aws_tf_mod_he_aws_tf_app_itf_stk_be.module.he_aws_tf_mod_aws_cc_app_itf_stk
The text was updated successfully, but these errors were encountered: