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

Change order of parsing so that include is parsed first #898

Merged
merged 2 commits into from
Oct 8, 2019

Conversation

yorinasub17
Copy link
Contributor

This is a fix for #814 (comment). Specifically, right now due to the parsing order get_parent_terragrunt_dir does not work in locals. This breaks usage of locals to refactor out a path calculation that depends on the parent dir, such as getting a default empty.yml file in the workaround for merging in optional variables from the directory hierarchy.

Note that this is a backwards incompatible change, where you can no longer reference locals in include. However, this is probably a worthy tradeoff where we are trading the not so useful function of referencing locals in include blocks (which will in 80% of use cases be find_in_parent_folders()) with the ability to use include dependent functions in the parent locals.

@yorinasub17
Copy link
Contributor Author

Merging this in. Thanks for review!

@yorinasub17 yorinasub17 merged commit bcfe3cf into master Oct 8, 2019
@yorinasub17 yorinasub17 deleted the yori-change-order branch October 8, 2019 23:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants