opentofu/internal/checks
Alisdair McDiarmid 8df065a2fe initwd: Switch from earlyconfig to configs
This is a mostly mechanical refactor with a handful of changes which
are necessary due to the semantic difference between earlyconfig and
configs.

When parsing root and descendant modules in the module installer, we now
check the core version requirements inline. If the Terraform version is
incompatible, we drop any other module loader diagnostics. This ensures
that future language additions don't clutter the output and confuse the
user.

We also add two new checks during the module load process:

* Don't try to load a module with a `nil` source address. This is a
  necessary change due to the move away from earlyconfig.

* Don't try to load a module with a blank name (i.e. `module ""`).
  Because our module loading manifest uses the stringified module path
  as its map key, this causes a collision with the root module, and a
  later panic. This is the bug which triggered this refactor in the
  first place.
2023-03-06 09:14:28 -05:00
..
testdata/happypath checks: A new package for modeling custom condition checks 2022-08-26 15:47:29 -07:00
doc.go checks: A new package for modeling custom condition checks 2022-08-26 15:47:29 -07:00
state_init.go core: Use the new checks package for condition tracking 2022-08-26 15:47:29 -07:00
state_report.go core: Propagate check results accurately from plan to apply 2022-08-26 15:47:29 -07:00
state_test.go initwd: Switch from earlyconfig to configs 2023-03-06 09:14:28 -05:00
state.go states: Two-level representation of check results 2022-08-26 15:47:29 -07:00
status_string.go checks: A new package for modeling custom condition checks 2022-08-26 15:47:29 -07:00
status.go checks: A new package for modeling custom condition checks 2022-08-26 15:47:29 -07:00