opentofu/internal/backend
Alisdair McDiarmid a3b1764fd7 backend/local: Fix lock when applying stale plan
When returning from the context method, a deferred function call checked
for error diagnostics in the `diags` variable, and unlocked the state if
any exist. This means that we need to be extra careful to mutate that
variable when returning errors, rather than returning a different set of
diags in the same position.

Previously this would result in an invalid plan file causing a lock to
become stuck.
2021-05-26 16:05:58 -04:00
..
init Move tfdiags/ to internal/tfdiags/ 2021-05-17 14:09:07 -07:00
local backend/local: Fix lock when applying stale plan 2021-05-26 16:05:58 -04:00
remote backend/remote: test new options and modes 2021-05-18 15:35:37 -07:00
remote-state Move states/ to internal/states/ 2021-05-17 14:09:07 -07:00
backend_test.go Move backend/ to internal/backend/ 2021-05-17 14:09:07 -07:00
backend.go Move terraform/ to internal/terraform/ 2021-05-17 14:09:07 -07:00
cli.go Move terraform/ to internal/terraform/ 2021-05-17 14:09:07 -07:00
operation_type.go Move backend/ to internal/backend/ 2021-05-17 14:09:07 -07:00
operationtype_string.go Move backend/ to internal/backend/ 2021-05-17 14:09:07 -07:00
testing.go Move states/ to internal/states/ 2021-05-17 14:09:07 -07:00
unparsed_value_test.go Move terraform/ to internal/terraform/ 2021-05-17 14:09:07 -07:00
unparsed_value.go Move terraform/ to internal/terraform/ 2021-05-17 14:09:07 -07:00