You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for the report and reproduction. I don't think this has anything to do with modules, it appears to be the format inside the map index that is throwing off the interpolator.
This reduced config crashes with apply
variable map {
default = {
a = "b"
}
}
output "formatted_index" {
value = "${var.map[format("%s", "a")]}"
}
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.
ghost
locked and limited conversation to collaborators
Apr 21, 2020
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Terraform Version
v0.7.5
Affected Resource(s)
This appears to be an issue with the core.
Terraform Configuration Files
Attached: tf-reproduce.zip
modules/subnets/main.tf
contains a mapoutput
:It's referenced in
main.tf
likePanic Output
crash.log.txt
Expected Behavior
terraform plan
should have shown a plan to create anaws_vpc
resource.Actual Behavior
💣🔥
panic: runtime error: index out of range
Steps to Reproduce
terraform get
terraform plan
If
cidr_block
is changed to"${module.subnets.vpcs["dev_aws_gen_us-east-1"]}"
theapply
works fine.References
Are there any other GitHub issues (open or closed) or Pull Requests that should be linked here? For example:
The text was updated successfully, but these errors were encountered: