1ae47ae314
The state refactoring command "terraform state mv" in Terraform 0.11 does not update existing dependency addresses recorded in the state when it moves objects around, and Terraform only updates the dependency addresses in the state when it performs a full update on a resource instance, and so it's a common problem for folks updating from Terraform 0.11 with resource names that are not valid identifiers to run into state upgrade errors even though they have followed the instructions produced by "terraform 0.12checklist". Dependencies are synced from config during every refresh walk anyway, so in practice we can get away with just discarding invalid dependency addresses and letting the refresh walk update them. In practice these addresses are unlikely to be pointing at a resource that actually exists anyway, because if so Terraform 0.12's configuration parser wouldn't be able to interpret it. Discarding invalid dependency addresses allows the state upgrade to complete successfully in such cases and thus gives the refresh step an opportunity to repair the problem. |
||
---|---|---|
.. | ||
v1-simple.in.tfstate | ||
v1-simple.out.tfstate | ||
v3-bigint.in.tfstate | ||
v3-bigint.out.tfstate | ||
v3-grabbag.in.tfstate | ||
v3-grabbag.out.tfstate | ||
v3-invalid-depends.in.tfstate | ||
v3-invalid-depends.out.tfstate | ||
v3-simple.in.tfstate | ||
v3-simple.out.tfstate | ||
v4-foreach.in.tfstate | ||
v4-foreach.out.tfstate | ||
v4-modules.in.tfstate | ||
v4-modules.out.tfstate | ||
v4-simple.in.tfstate | ||
v4-simple.out.tfstate |