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

Move block expanding to under the terraform package #1526

Merged
merged 1 commit into from
Oct 1, 2022

Conversation

wata727
Copy link
Member

@wata727 wata727 commented Sep 24, 2022

As part of #1510, move the remaining evaluation logic into the terraform package. This PR will completely remove runner_eval.go.

Previously, runner was responsible for checking whether resources/modules are unevaluated such as count = 0 or for_each = [], but moved the logic around evaluation to the terraform.Evaluator by expanding blocks when retrieving content.

This is also a preparation for #1139. Currently expandBlocks just checks if count/for_each is 0 or empty, but in the future we could change hclext.BodyContent accordingly.

ToDo

  • Tweak godoc
  • Add tests

@wata727 wata727 force-pushed the refactor_block_expanding branch from 2816e44 to 41a02e6 Compare September 25, 2022 16:08
@wata727 wata727 marked this pull request as ready for review September 25, 2022 16:12
@wata727 wata727 merged commit a874498 into master Oct 1, 2022
@wata727 wata727 deleted the refactor_block_expanding branch October 1, 2022 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant