diff --git a/addrs/module_instance.go b/addrs/module_instance.go index 396d5f6e00..adde944169 100644 --- a/addrs/module_instance.go +++ b/addrs/module_instance.go @@ -9,7 +9,7 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/gocty" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ModuleInstance is an address for a particular module instance within the diff --git a/addrs/parse_ref.go b/addrs/parse_ref.go index 62f244e1a6..9dbeb89662 100644 --- a/addrs/parse_ref.go +++ b/addrs/parse_ref.go @@ -5,7 +5,7 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Reference describes a reference to an address with source location diff --git a/addrs/parse_ref_test.go b/addrs/parse_ref_test.go index f7f1949ae5..37b1bfce0e 100644 --- a/addrs/parse_ref_test.go +++ b/addrs/parse_ref_test.go @@ -6,7 +6,7 @@ import ( "github.com/go-test/deep" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/addrs/parse_target.go b/addrs/parse_target.go index c308525f50..f75e652369 100644 --- a/addrs/parse_target.go +++ b/addrs/parse_target.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/hcl/v2" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Target describes a targeted address with source location information. diff --git a/addrs/parse_target_test.go b/addrs/parse_target_test.go index 84796084f0..6e838d0e51 100644 --- a/addrs/parse_target_test.go +++ b/addrs/parse_target_test.go @@ -6,7 +6,7 @@ import ( "github.com/go-test/deep" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestParseTarget(t *testing.T) { diff --git a/addrs/provider.go b/addrs/provider.go index c0055c66fb..1f21fec91c 100644 --- a/addrs/provider.go +++ b/addrs/provider.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/hcl/v2" svchost "github.com/hashicorp/terraform-svchost" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Provider encapsulates a single provider type. In the future this will be diff --git a/addrs/provider_config.go b/addrs/provider_config.go index 5b1d2e1e0f..88331da851 100644 --- a/addrs/provider_config.go +++ b/addrs/provider_config.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/hashicorp/hcl/v2" diff --git a/command/apply.go b/command/apply.go index 50fba0c0ab..132aa5324c 100644 --- a/command/apply.go +++ b/command/apply.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/backend" remoteBackend "github.com/hashicorp/terraform/internal/backend/remote" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans/planfile" - "github.com/hashicorp/terraform/tfdiags" ) // ApplyCommand is a Command implementation that applies a Terraform diff --git a/command/apply_test.go b/command/apply_test.go index 464b4f4023..a6a8bbb6ef 100644 --- a/command/apply_test.go +++ b/command/apply_test.go @@ -23,12 +23,12 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" ) diff --git a/command/arguments/apply.go b/command/arguments/apply.go index 267c8e5397..f18eef225d 100644 --- a/command/arguments/apply.go +++ b/command/arguments/apply.go @@ -3,8 +3,8 @@ package arguments import ( "fmt" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" ) // Apply represents the command-line arguments for the apply command. diff --git a/command/arguments/extended.go b/command/arguments/extended.go index c4b98336eb..bbe487d600 100644 --- a/command/arguments/extended.go +++ b/command/arguments/extended.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" ) // DefaultParallelism is the limit Terraform places on total parallel diff --git a/command/arguments/output.go b/command/arguments/output.go index f77c283ccc..debf05dd83 100644 --- a/command/arguments/output.go +++ b/command/arguments/output.go @@ -1,7 +1,7 @@ package arguments import ( - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Output represents the command-line arguments for the output command. diff --git a/command/arguments/output_test.go b/command/arguments/output_test.go index 304a156bff..cb25808137 100644 --- a/command/arguments/output_test.go +++ b/command/arguments/output_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/davecgh/go-spew/spew" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestParseOutput_valid(t *testing.T) { diff --git a/command/arguments/plan.go b/command/arguments/plan.go index 0a93759440..2300dc7a5d 100644 --- a/command/arguments/plan.go +++ b/command/arguments/plan.go @@ -1,7 +1,7 @@ package arguments import ( - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Plan represents the command-line arguments for the plan command. diff --git a/command/arguments/refresh.go b/command/arguments/refresh.go index 0e35483aa7..bc08d9df4d 100644 --- a/command/arguments/refresh.go +++ b/command/arguments/refresh.go @@ -1,7 +1,7 @@ package arguments import ( - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Refresh represents the command-line arguments for the apply command. diff --git a/command/arguments/test.go b/command/arguments/test.go index c49759a8e9..8ffbd4914d 100644 --- a/command/arguments/test.go +++ b/command/arguments/test.go @@ -4,7 +4,7 @@ import ( "flag" "io/ioutil" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Test represents the command line arguments for the "terraform test" command. diff --git a/command/arguments/test_test.go b/command/arguments/test_test.go index 7cd671a77c..9a1c7fed01 100644 --- a/command/arguments/test_test.go +++ b/command/arguments/test_test.go @@ -5,7 +5,7 @@ import ( "github.com/apparentlymart/go-shquot/shquot" "github.com/google/go-cmp/cmp" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestParseTest(t *testing.T) { diff --git a/command/arguments/validate.go b/command/arguments/validate.go index 71b31e09aa..daadd7ed53 100644 --- a/command/arguments/validate.go +++ b/command/arguments/validate.go @@ -1,7 +1,7 @@ package arguments import ( - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Validate represents the command-line arguments for the validate command. diff --git a/command/arguments/validate_test.go b/command/arguments/validate_test.go index 29b90d16c2..e744055507 100644 --- a/command/arguments/validate_test.go +++ b/command/arguments/validate_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/davecgh/go-spew/spew" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestParseValidate_valid(t *testing.T) { diff --git a/command/cliconfig/cliconfig.go b/command/cliconfig/cliconfig.go index 0896738c9a..7f3b1aa73d 100644 --- a/command/cliconfig/cliconfig.go +++ b/command/cliconfig/cliconfig.go @@ -18,7 +18,7 @@ import ( "github.com/hashicorp/hcl" svchost "github.com/hashicorp/terraform-svchost" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) const pluginCacheDirEnvVar = "TF_PLUGIN_CACHE_DIR" diff --git a/command/cliconfig/provider_installation.go b/command/cliconfig/provider_installation.go index a60cd1c771..8b5f5cfb19 100644 --- a/command/cliconfig/provider_installation.go +++ b/command/cliconfig/provider_installation.go @@ -8,7 +8,7 @@ import ( hclast "github.com/hashicorp/hcl/hcl/ast" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/getproviders" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ProviderInstallation is the structure of the "provider_installation" diff --git a/command/clistate/state.go b/command/clistate/state.go index 5aa3f1d296..b24562f5f7 100644 --- a/command/clistate/state.go +++ b/command/clistate/state.go @@ -12,8 +12,8 @@ import ( "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/helper/slowmessage" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" ) const ( diff --git a/command/console.go b/command/console.go index c6903e5ea3..853f136bf3 100644 --- a/command/console.go +++ b/command/console.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/terraform/internal/backend" "github.com/hashicorp/terraform/internal/helper/wrappedstreams" "github.com/hashicorp/terraform/internal/repl" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/fmt.go b/command/fmt.go index d133e307b4..1b2a6f79cc 100644 --- a/command/fmt.go +++ b/command/fmt.go @@ -17,7 +17,7 @@ import ( "github.com/mitchellh/cli" "github.com/hashicorp/terraform/configs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) const ( diff --git a/command/format/diagnostic.go b/command/format/diagnostic.go index 2d8522dea8..e9699f1d42 100644 --- a/command/format/diagnostic.go +++ b/command/format/diagnostic.go @@ -8,7 +8,7 @@ import ( "strings" viewsjson "github.com/hashicorp/terraform/command/views/json" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/colorstring" wordwrap "github.com/mitchellh/go-wordwrap" diff --git a/command/format/diagnostic_test.go b/command/format/diagnostic_test.go index 6680442d81..e2f2fc5122 100644 --- a/command/format/diagnostic_test.go +++ b/command/format/diagnostic_test.go @@ -12,7 +12,7 @@ import ( viewsjson "github.com/hashicorp/terraform/command/views/json" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestDiagnostic(t *testing.T) { diff --git a/command/get.go b/command/get.go index 238f3ec273..170e194007 100644 --- a/command/get.go +++ b/command/get.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // GetCommand is a Command implementation that takes a Terraform diff --git a/command/graph.go b/command/graph.go index 26a0bbe1cb..2aff491be2 100644 --- a/command/graph.go +++ b/command/graph.go @@ -4,8 +4,8 @@ import ( "fmt" "strings" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans/planfile" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/internal/backend" "github.com/hashicorp/terraform/internal/dag" diff --git a/command/import.go b/command/import.go index fcba25fafe..bf93261dbe 100644 --- a/command/import.go +++ b/command/import.go @@ -15,8 +15,8 @@ import ( "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // ImportCommand is a cli.Command implementation that imports resources diff --git a/command/import_test.go b/command/import_test.go index e71e4c22c5..1e37b76852 100644 --- a/command/import_test.go +++ b/command/import_test.go @@ -13,8 +13,8 @@ import ( "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/copy" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" ) func TestImport(t *testing.T) { diff --git a/command/init.go b/command/init.go index f12a91682e..e87c70e349 100644 --- a/command/init.go +++ b/command/init.go @@ -19,9 +19,9 @@ import ( backendInit "github.com/hashicorp/terraform/internal/backend/init" "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/providercache" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" ) diff --git a/command/login.go b/command/login.go index a519ec7996..d29df2ed43 100644 --- a/command/login.go +++ b/command/login.go @@ -22,8 +22,8 @@ import ( "github.com/hashicorp/terraform-svchost/disco" "github.com/hashicorp/terraform/command/cliconfig" "github.com/hashicorp/terraform/internal/httpclient" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" uuid "github.com/hashicorp/go-uuid" "golang.org/x/oauth2" diff --git a/command/logout.go b/command/logout.go index 5f2af1104b..36eaac4720 100644 --- a/command/logout.go +++ b/command/logout.go @@ -7,7 +7,7 @@ import ( svchost "github.com/hashicorp/terraform-svchost" "github.com/hashicorp/terraform/command/cliconfig" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // LogoutCommand is a Command implementation which removes stored credentials diff --git a/command/meta.go b/command/meta.go index cce6f2a66d..6605fb066b 100644 --- a/command/meta.go +++ b/command/meta.go @@ -28,10 +28,10 @@ import ( "github.com/hashicorp/terraform/internal/backend/local" "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/terminal" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" "github.com/mitchellh/colorstring" diff --git a/command/meta_backend.go b/command/meta_backend.go index 4185d241c2..1f45af29a0 100644 --- a/command/meta_backend.go +++ b/command/meta_backend.go @@ -21,10 +21,10 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/backend" remoteBackend "github.com/hashicorp/terraform/internal/backend/remote" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ctyjson "github.com/zclconf/go-cty/cty/json" diff --git a/command/meta_config.go b/command/meta_config.go index 9ebe892a59..7ddd3dd5d4 100644 --- a/command/meta_config.go +++ b/command/meta_config.go @@ -16,8 +16,8 @@ import ( "github.com/hashicorp/terraform/internal/earlyconfig" "github.com/hashicorp/terraform/internal/initwd" "github.com/hashicorp/terraform/internal/registry" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" ) diff --git a/command/meta_dependencies.go b/command/meta_dependencies.go index 4a80adfc3f..efda3f1032 100644 --- a/command/meta_dependencies.go +++ b/command/meta_dependencies.go @@ -4,7 +4,7 @@ import ( "os" "github.com/hashicorp/terraform/internal/depsfile" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // dependenclyLockFilename is the filename of the dependency lock file. diff --git a/command/meta_providers.go b/command/meta_providers.go index eb77eb93a9..1b242fb8fd 100644 --- a/command/meta_providers.go +++ b/command/meta_providers.go @@ -17,10 +17,10 @@ import ( "github.com/hashicorp/terraform/internal/logging" "github.com/hashicorp/terraform/internal/moduletest" "github.com/hashicorp/terraform/internal/providercache" + "github.com/hashicorp/terraform/internal/tfdiags" tfplugin "github.com/hashicorp/terraform/plugin" tfplugin6 "github.com/hashicorp/terraform/plugin6" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" ) // The TF_DISABLE_PLUGIN_TLS environment variable is intended only for use by diff --git a/command/meta_vars.go b/command/meta_vars.go index ba666eea17..4fd0920e6e 100644 --- a/command/meta_vars.go +++ b/command/meta_vars.go @@ -11,8 +11,8 @@ import ( hcljson "github.com/hashicorp/hcl/v2/json" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // VarEnvPrefix is the prefix for environment variables that represent values diff --git a/command/output.go b/command/output.go index c228bf377e..2561e83376 100644 --- a/command/output.go +++ b/command/output.go @@ -6,8 +6,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // OutputCommand is a Command implementation that reads an output diff --git a/command/plan.go b/command/plan.go index 4a92f7dae0..ccbf711b42 100644 --- a/command/plan.go +++ b/command/plan.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/backend" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // PlanCommand is a Command implementation that compares a Terraform diff --git a/command/plan_test.go b/command/plan_test.go index d925c121a9..9023ad7f39 100644 --- a/command/plan_test.go +++ b/command/plan_test.go @@ -19,11 +19,11 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" backendinit "github.com/hashicorp/terraform/internal/backend/init" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func TestPlan(t *testing.T) { diff --git a/command/providers.go b/command/providers.go index a846b85dcd..c28173af11 100644 --- a/command/providers.go +++ b/command/providers.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/getproviders" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/xlab/treeprint" ) diff --git a/command/providers_lock.go b/command/providers_lock.go index 1c8d3ae2ab..e2e51dd58d 100644 --- a/command/providers_lock.go +++ b/command/providers_lock.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/terraform/internal/depsfile" "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/providercache" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ProvidersLockCommand is a Command implementation that implements the diff --git a/command/providers_mirror.go b/command/providers_mirror.go index 3aacf1dc11..e816a114fb 100644 --- a/command/providers_mirror.go +++ b/command/providers_mirror.go @@ -12,7 +12,7 @@ import ( "github.com/hashicorp/go-getter" "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/httpclient" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ProvidersMirrorCommand is a Command implementation that implements the diff --git a/command/providers_schema.go b/command/providers_schema.go index 324c5600c9..5013a67091 100644 --- a/command/providers_schema.go +++ b/command/providers_schema.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/terraform/command/jsonprovider" "github.com/hashicorp/terraform/internal/backend" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ProvidersCommand is a Command implementation that prints out information diff --git a/command/push.go b/command/push.go index 27e6d6051f..ee1544926d 100644 --- a/command/push.go +++ b/command/push.go @@ -3,7 +3,7 @@ package command import ( "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) type PushCommand struct { diff --git a/command/refresh.go b/command/refresh.go index c5093e7659..0a37b05e80 100644 --- a/command/refresh.go +++ b/command/refresh.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/backend" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // RefreshCommand is a cli.Command implementation that refreshes the state diff --git a/command/refresh_test.go b/command/refresh_test.go index e593e494f6..9d56eaaab5 100644 --- a/command/refresh_test.go +++ b/command/refresh_test.go @@ -18,11 +18,11 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statefile" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" ) var equateEmpty = cmpopts.EquateEmpty() diff --git a/command/show.go b/command/show.go index cd549cf15b..f524002f0d 100644 --- a/command/show.go +++ b/command/show.go @@ -11,11 +11,11 @@ import ( "github.com/hashicorp/terraform/command/jsonstate" "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/planfile" "github.com/hashicorp/terraform/states/statefile" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" ) // ShowCommand is a Command implementation that reads and outputs the diff --git a/command/state_list.go b/command/state_list.go index 5e2f2527c3..b95a2aa2fc 100644 --- a/command/state_list.go +++ b/command/state_list.go @@ -5,8 +5,8 @@ import ( "strings" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/state_meta.go b/command/state_meta.go index 4beeb9e024..1dfd23b747 100644 --- a/command/state_meta.go +++ b/command/state_meta.go @@ -6,9 +6,9 @@ import ( "time" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" backendLocal "github.com/hashicorp/terraform/internal/backend/local" ) diff --git a/command/state_mv.go b/command/state_mv.go index 2ecf8349a8..8ca430e521 100644 --- a/command/state_mv.go +++ b/command/state_mv.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/state_replace_provider.go b/command/state_replace_provider.go index c7ea71d667..5c1d4a1f05 100644 --- a/command/state_replace_provider.go +++ b/command/state_replace_provider.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/state_rm.go b/command/state_rm.go index 70d47f8350..f55204291f 100644 --- a/command/state_rm.go +++ b/command/state_rm.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/taint.go b/command/taint.go index f83db6afa3..be1c61382b 100644 --- a/command/taint.go +++ b/command/taint.go @@ -9,9 +9,9 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // TaintCommand is a cli.Command implementation that manually taints diff --git a/command/test.go b/command/test.go index 9e6d19e04d..fb90293bae 100644 --- a/command/test.go +++ b/command/test.go @@ -21,11 +21,11 @@ import ( "github.com/hashicorp/terraform/internal/initwd" "github.com/hashicorp/terraform/internal/moduletest" "github.com/hashicorp/terraform/internal/providercache" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // TestCommand is the implementation of "terraform test". diff --git a/command/unlock.go b/command/unlock.go index ce8d436069..3dbd0e25e8 100644 --- a/command/unlock.go +++ b/command/unlock.go @@ -7,8 +7,8 @@ import ( "github.com/hashicorp/terraform/states/statemgr" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" ) diff --git a/command/untaint.go b/command/untaint.go index 33c3f6756c..52b87a67a4 100644 --- a/command/untaint.go +++ b/command/untaint.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // UntaintCommand is a cli.Command implementation that manually untaints diff --git a/command/validate.go b/command/validate.go index 765a329210..7d13dd933a 100644 --- a/command/validate.go +++ b/command/validate.go @@ -9,8 +9,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // ValidateCommand is a Command implementation that validates the terraform files diff --git a/command/views/apply.go b/command/views/apply.go index 988924f999..9626bf1254 100644 --- a/command/views/apply.go +++ b/command/views/apply.go @@ -6,9 +6,9 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/format" "github.com/hashicorp/terraform/command/views/json" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // The Apply view is used for the apply command. diff --git a/command/views/json/diagnostic.go b/command/views/json/diagnostic.go index 1290e6bb5f..b427d443c3 100644 --- a/command/views/json/diagnostic.go +++ b/command/views/json/diagnostic.go @@ -10,7 +10,7 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hcled" "github.com/hashicorp/hcl/v2/hclparse" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/command/views/json/diagnostic_test.go b/command/views/json/diagnostic_test.go index a11d815e2c..ec34da2484 100644 --- a/command/views/json/diagnostic_test.go +++ b/command/views/json/diagnostic_test.go @@ -12,7 +12,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hcltest" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/command/views/json/output.go b/command/views/json/output.go index 1cb19a4310..be49260c9d 100644 --- a/command/views/json/output.go +++ b/command/views/json/output.go @@ -6,8 +6,8 @@ import ( ctyjson "github.com/zclconf/go-cty/cty/json" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) type Output struct { diff --git a/command/views/json_view.go b/command/views/json_view.go index f18886e804..6540a487e1 100644 --- a/command/views/json_view.go +++ b/command/views/json_view.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/go-hclog" "github.com/hashicorp/terraform/command/views/json" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" tfversion "github.com/hashicorp/terraform/version" ) diff --git a/command/views/json_view_test.go b/command/views/json_view_test.go index 9aa4c692df..d206cad8b9 100644 --- a/command/views/json_view_test.go +++ b/command/views/json_view_test.go @@ -11,8 +11,8 @@ import ( "github.com/hashicorp/terraform/addrs" viewsjson "github.com/hashicorp/terraform/command/views/json" "github.com/hashicorp/terraform/internal/terminal" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" ) diff --git a/command/views/operation.go b/command/views/operation.go index 3f29b08887..b54b4193a3 100644 --- a/command/views/operation.go +++ b/command/views/operation.go @@ -9,10 +9,10 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/format" "github.com/hashicorp/terraform/command/views/json" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states/statefile" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) type Operation interface { diff --git a/command/views/output.go b/command/views/output.go index 6aec9dea85..dbe347e53c 100644 --- a/command/views/output.go +++ b/command/views/output.go @@ -13,8 +13,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/internal/repl" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // The Output view renders either one or all outputs, depending on whether or diff --git a/command/views/plan.go b/command/views/plan.go index fd39ccf4a6..2dedb33f6c 100644 --- a/command/views/plan.go +++ b/command/views/plan.go @@ -9,10 +9,10 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/format" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // The Plan view is used for the plan command. diff --git a/command/views/refresh.go b/command/views/refresh.go index 39db5a3bf1..1e08365fae 100644 --- a/command/views/refresh.go +++ b/command/views/refresh.go @@ -5,9 +5,9 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/views/json" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) // The Refresh view is used for the refresh command. diff --git a/command/views/test.go b/command/views/test.go index 4ba3162d8b..e2f3003b5f 100644 --- a/command/views/test.go +++ b/command/views/test.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform/command/format" "github.com/hashicorp/terraform/internal/moduletest" "github.com/hashicorp/terraform/internal/terminal" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/colorstring" ) diff --git a/command/views/validate.go b/command/views/validate.go index 864f4e2942..31c9f2c768 100644 --- a/command/views/validate.go +++ b/command/views/validate.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/format" viewsjson "github.com/hashicorp/terraform/command/views/json" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // The Validate is used for the validate command. diff --git a/command/views/validate_test.go b/command/views/validate_test.go index 65969a4100..4825f6c0d7 100644 --- a/command/views/validate_test.go +++ b/command/views/validate_test.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/internal/terminal" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestValidateHuman(t *testing.T) { diff --git a/command/views/view.go b/command/views/view.go index f59fd4405e..b48ae6541d 100644 --- a/command/views/view.go +++ b/command/views/view.go @@ -4,7 +4,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/format" "github.com/hashicorp/terraform/internal/terminal" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/colorstring" ) diff --git a/command/workspace_delete.go b/command/workspace_delete.go index 9418e24493..87c4a35b05 100644 --- a/command/workspace_delete.go +++ b/command/workspace_delete.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/cli" "github.com/posener/complete" ) diff --git a/command/workspace_list.go b/command/workspace_list.go index dda891d4e2..aac6bc97d8 100644 --- a/command/workspace_list.go +++ b/command/workspace_list.go @@ -5,7 +5,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/posener/complete" ) diff --git a/command/workspace_new.go b/command/workspace_new.go index 055680af8c..3e95a86f36 100644 --- a/command/workspace_new.go +++ b/command/workspace_new.go @@ -9,8 +9,8 @@ import ( "github.com/hashicorp/terraform/command/arguments" "github.com/hashicorp/terraform/command/clistate" "github.com/hashicorp/terraform/command/views" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/statefile" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/cli" "github.com/posener/complete" ) diff --git a/command/workspace_select.go b/command/workspace_select.go index db0d67b96a..645a9c2bcb 100644 --- a/command/workspace_select.go +++ b/command/workspace_select.go @@ -4,7 +4,7 @@ import ( "fmt" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/mitchellh/cli" "github.com/posener/complete" ) diff --git a/configs/configschema/coerce_value_test.go b/configs/configschema/coerce_value_test.go index 974dfdd35f..3f57b174be 100644 --- a/configs/configschema/coerce_value_test.go +++ b/configs/configschema/coerce_value_test.go @@ -5,7 +5,7 @@ import ( "github.com/zclconf/go-cty/cty" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestCoerceValue(t *testing.T) { diff --git a/configs/configschema/validate_traversal.go b/configs/configschema/validate_traversal.go index 83368412fa..ca293af98a 100644 --- a/configs/configschema/validate_traversal.go +++ b/configs/configschema/validate_traversal.go @@ -9,7 +9,7 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/internal/didyoumean" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // StaticValidateTraversal checks whether the given traversal (which must be diff --git a/configs/provider.go b/configs/provider.go index 7b89a06c09..4005a27829 100644 --- a/configs/provider.go +++ b/configs/provider.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Provider represents a "provider" block in a module or file. A provider diff --git a/internal/backend/backend.go b/internal/backend/backend.go index 349fe149f6..02a6ebf74a 100644 --- a/internal/backend/backend.go +++ b/internal/backend/backend.go @@ -17,12 +17,12 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configload" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/planfile" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/mitchellh/go-homedir" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/backend/init/init.go b/internal/backend/init/init.go index 922a64e14e..5abc8754d4 100644 --- a/internal/backend/init/init.go +++ b/internal/backend/init/init.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-svchost/disco" "github.com/hashicorp/terraform/internal/backend" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" backendLocal "github.com/hashicorp/terraform/internal/backend/local" diff --git a/internal/backend/local/backend.go b/internal/backend/local/backend.go index 343452cbd0..a47192d4d6 100644 --- a/internal/backend/local/backend.go +++ b/internal/backend/local/backend.go @@ -14,9 +14,9 @@ import ( "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/backend/local/backend_apply.go b/internal/backend/local/backend_apply.go index dcc1f7c6bf..8f75419ed1 100644 --- a/internal/backend/local/backend_apply.go +++ b/internal/backend/local/backend_apply.go @@ -8,12 +8,12 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/command/views" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statefile" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func (b *Local) opApply( diff --git a/internal/backend/local/backend_apply_test.go b/internal/backend/local/backend_apply_test.go index 9f3b547b84..bc74b9eb6b 100644 --- a/internal/backend/local/backend_apply_test.go +++ b/internal/backend/local/backend_apply_test.go @@ -18,12 +18,12 @@ import ( "github.com/hashicorp/terraform/internal/backend" "github.com/hashicorp/terraform/internal/initwd" "github.com/hashicorp/terraform/internal/terminal" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func TestLocal_applyBasic(t *testing.T) { diff --git a/internal/backend/local/backend_local.go b/internal/backend/local/backend_local.go index 58ce76da1e..bb47d559a4 100644 --- a/internal/backend/local/backend_local.go +++ b/internal/backend/local/backend_local.go @@ -10,10 +10,10 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configload" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans/planfile" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/backend/local/backend_plan.go b/internal/backend/local/backend_plan.go index cae8b19aaa..b29b7db7d0 100644 --- a/internal/backend/local/backend_plan.go +++ b/internal/backend/local/backend_plan.go @@ -6,12 +6,12 @@ import ( "log" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/planfile" "github.com/hashicorp/terraform/states/statefile" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func (b *Local) opPlan( diff --git a/internal/backend/local/backend_refresh.go b/internal/backend/local/backend_refresh.go index deaf44adac..e74fc0751f 100644 --- a/internal/backend/local/backend_refresh.go +++ b/internal/backend/local/backend_refresh.go @@ -8,9 +8,9 @@ import ( "github.com/hashicorp/errwrap" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" ) func (b *Local) opRefresh( diff --git a/internal/backend/remote/backend.go b/internal/backend/remote/backend.go index a654d72928..021bc5e329 100644 --- a/internal/backend/remote/backend.go +++ b/internal/backend/remote/backend.go @@ -18,10 +18,10 @@ import ( "github.com/hashicorp/terraform-svchost/disco" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/remote" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" "github.com/mitchellh/cli" "github.com/mitchellh/colorstring" diff --git a/internal/backend/remote/backend_apply.go b/internal/backend/remote/backend_apply.go index ceb11be417..7819ade3b5 100644 --- a/internal/backend/remote/backend_apply.go +++ b/internal/backend/remote/backend_apply.go @@ -10,9 +10,9 @@ import ( tfe "github.com/hashicorp/go-tfe" version "github.com/hashicorp/go-version" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func (b *Remote) opApply(stopCtx, cancelCtx context.Context, op *backend.Operation, w *tfe.Workspace) (*tfe.Run, error) { diff --git a/internal/backend/remote/backend_context.go b/internal/backend/remote/backend_context.go index 01aa525a5a..10ea8214eb 100644 --- a/internal/backend/remote/backend_context.go +++ b/internal/backend/remote/backend_context.go @@ -12,9 +12,9 @@ import ( "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/statemgr" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/backend/remote/backend_plan.go b/internal/backend/remote/backend_plan.go index 0c3a6e6404..2d16aa447c 100644 --- a/internal/backend/remote/backend_plan.go +++ b/internal/backend/remote/backend_plan.go @@ -17,8 +17,8 @@ import ( tfe "github.com/hashicorp/go-tfe" version "github.com/hashicorp/go-version" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" ) var planConfigurationVersionsPollInterval = 500 * time.Millisecond diff --git a/internal/backend/remote/backend_test.go b/internal/backend/remote/backend_test.go index 049359c2bc..3f0755a0e5 100644 --- a/internal/backend/remote/backend_test.go +++ b/internal/backend/remote/backend_test.go @@ -11,7 +11,7 @@ import ( version "github.com/hashicorp/go-version" "github.com/hashicorp/terraform-svchost/disco" "github.com/hashicorp/terraform/internal/backend" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" tfversion "github.com/hashicorp/terraform/version" "github.com/zclconf/go-cty/cty" diff --git a/internal/backend/remote/testing.go b/internal/backend/remote/testing.go index af8864d44e..211a5e30d1 100644 --- a/internal/backend/remote/testing.go +++ b/internal/backend/remote/testing.go @@ -17,10 +17,10 @@ import ( "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/backend" "github.com/hashicorp/terraform/internal/httpclient" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states/remote" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/version" "github.com/mitchellh/cli" "github.com/zclconf/go-cty/cty" diff --git a/internal/backend/testing.go b/internal/backend/testing.go index 6a4c134c73..cfc26725d4 100644 --- a/internal/backend/testing.go +++ b/internal/backend/testing.go @@ -12,9 +12,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" ) // TestBackendConfig validates and configures the backend with the diff --git a/internal/backend/unparsed_value.go b/internal/backend/unparsed_value.go index 22bc813694..61a14c9eb4 100644 --- a/internal/backend/unparsed_value.go +++ b/internal/backend/unparsed_value.go @@ -5,8 +5,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/configs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/backend/unparsed_value_test.go b/internal/backend/unparsed_value_test.go index 0c37adbc60..e172d4b0ce 100644 --- a/internal/backend/unparsed_value_test.go +++ b/internal/backend/unparsed_value_test.go @@ -9,8 +9,8 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/configs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/terraform" - "github.com/hashicorp/terraform/tfdiags" ) func TestParseVariableValuesUndeclared(t *testing.T) { diff --git a/internal/builtin/providers/terraform/data_source_state.go b/internal/builtin/providers/terraform/data_source_state.go index 00d9ebe1ef..ff4b8b66e2 100644 --- a/internal/builtin/providers/terraform/data_source_state.go +++ b/internal/builtin/providers/terraform/data_source_state.go @@ -7,8 +7,8 @@ import ( "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/backend" "github.com/hashicorp/terraform/internal/backend/remote" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" backendInit "github.com/hashicorp/terraform/internal/backend/init" diff --git a/internal/builtin/providers/terraform/data_source_state_test.go b/internal/builtin/providers/terraform/data_source_state_test.go index a55ce6eacf..2b53508686 100644 --- a/internal/builtin/providers/terraform/data_source_state_test.go +++ b/internal/builtin/providers/terraform/data_source_state_test.go @@ -8,8 +8,8 @@ import ( "github.com/apparentlymart/go-dump/dump" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/backend" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states/statemgr" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/dag/dag.go b/internal/dag/dag.go index 37e13c7f25..d72b3988e0 100644 --- a/internal/dag/dag.go +++ b/internal/dag/dag.go @@ -5,7 +5,7 @@ import ( "sort" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/go-multierror" ) diff --git a/internal/dag/dag_test.go b/internal/dag/dag_test.go index 90a9f75c62..0402cda39d 100644 --- a/internal/dag/dag_test.go +++ b/internal/dag/dag_test.go @@ -10,7 +10,7 @@ import ( "sync" "testing" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" _ "github.com/hashicorp/terraform/internal/logging" ) diff --git a/internal/dag/walk.go b/internal/dag/walk.go index 26b249230f..ff8afeac7c 100644 --- a/internal/dag/walk.go +++ b/internal/dag/walk.go @@ -6,7 +6,7 @@ import ( "sync" "time" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Walker is used to walk every vertex of a graph in parallel. diff --git a/internal/dag/walk_test.go b/internal/dag/walk_test.go index 5464248b13..fc5844e2e1 100644 --- a/internal/dag/walk_test.go +++ b/internal/dag/walk_test.go @@ -7,7 +7,7 @@ import ( "testing" "time" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestWalker_basic(t *testing.T) { diff --git a/internal/depsfile/locks_file.go b/internal/depsfile/locks_file.go index 2c38175a33..10f32e11f7 100644 --- a/internal/depsfile/locks_file.go +++ b/internal/depsfile/locks_file.go @@ -14,7 +14,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/replacefile" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/version" ) diff --git a/internal/depsfile/locks_file_test.go b/internal/depsfile/locks_file_test.go index 9e0d0f429c..9be6e44dfa 100644 --- a/internal/depsfile/locks_file_test.go +++ b/internal/depsfile/locks_file_test.go @@ -11,7 +11,7 @@ import ( "github.com/google/go-cmp/cmp" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/getproviders" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestLoadLocksFromFile(t *testing.T) { diff --git a/internal/earlyconfig/config.go b/internal/earlyconfig/config.go index 2e6d0a90a7..0934937441 100644 --- a/internal/earlyconfig/config.go +++ b/internal/earlyconfig/config.go @@ -8,9 +8,9 @@ import ( "github.com/hashicorp/terraform-config-inspect/tfconfig" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/getproviders" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/moduledeps" "github.com/hashicorp/terraform/plugin/discovery" - "github.com/hashicorp/terraform/tfdiags" ) // A Config is a node in the tree of modules within a configuration. diff --git a/internal/earlyconfig/config_build.go b/internal/earlyconfig/config_build.go index 770d5dfbe3..18b21a177a 100644 --- a/internal/earlyconfig/config_build.go +++ b/internal/earlyconfig/config_build.go @@ -8,7 +8,7 @@ import ( version "github.com/hashicorp/go-version" "github.com/hashicorp/terraform-config-inspect/tfconfig" "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // BuildConfig constructs a Config from a root module by loading all of its diff --git a/internal/earlyconfig/config_test.go b/internal/earlyconfig/config_test.go index 20f15f7b97..d31f07844e 100644 --- a/internal/earlyconfig/config_test.go +++ b/internal/earlyconfig/config_test.go @@ -11,7 +11,7 @@ import ( svchost "github.com/hashicorp/terraform-svchost" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/getproviders" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestConfigProviderRequirements(t *testing.T) { diff --git a/internal/earlyconfig/diagnostics.go b/internal/earlyconfig/diagnostics.go index 9b2fd7f71d..9a6b266363 100644 --- a/internal/earlyconfig/diagnostics.go +++ b/internal/earlyconfig/diagnostics.go @@ -4,7 +4,7 @@ import ( "fmt" "github.com/hashicorp/terraform-config-inspect/tfconfig" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func wrapDiagnostics(diags tfconfig.Diagnostics) tfdiags.Diagnostics { diff --git a/internal/earlyconfig/module.go b/internal/earlyconfig/module.go index d2d628797a..e4edba0e05 100644 --- a/internal/earlyconfig/module.go +++ b/internal/earlyconfig/module.go @@ -2,7 +2,7 @@ package earlyconfig import ( "github.com/hashicorp/terraform-config-inspect/tfconfig" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // LoadModule loads some top-level metadata for the module in the given diff --git a/internal/initwd/from_module.go b/internal/initwd/from_module.go index 14e5a124ee..28ac987e0c 100644 --- a/internal/initwd/from_module.go +++ b/internal/initwd/from_module.go @@ -16,7 +16,7 @@ import ( "github.com/hashicorp/terraform-config-inspect/tfconfig" "github.com/hashicorp/terraform/internal/modsdir" "github.com/hashicorp/terraform/internal/registry" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) const initFromModuleRootCallName = "root" diff --git a/internal/initwd/from_module_test.go b/internal/initwd/from_module_test.go index f7e07fb4de..6c8452b042 100644 --- a/internal/initwd/from_module_test.go +++ b/internal/initwd/from_module_test.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/terraform/configs/configload" "github.com/hashicorp/terraform/internal/copy" "github.com/hashicorp/terraform/internal/registry" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestDirFromModule_registry(t *testing.T) { diff --git a/internal/initwd/load_config.go b/internal/initwd/load_config.go index 6f77dcd84b..6dc032ba17 100644 --- a/internal/initwd/load_config.go +++ b/internal/initwd/load_config.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/terraform-config-inspect/tfconfig" "github.com/hashicorp/terraform/internal/earlyconfig" "github.com/hashicorp/terraform/internal/modsdir" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // LoadConfig loads a full configuration tree that has previously had all of diff --git a/internal/initwd/module_install.go b/internal/initwd/module_install.go index f97bea7814..2b1a12e963 100644 --- a/internal/initwd/module_install.go +++ b/internal/initwd/module_install.go @@ -15,7 +15,7 @@ import ( "github.com/hashicorp/terraform/internal/registry" "github.com/hashicorp/terraform/internal/registry/regsrc" "github.com/hashicorp/terraform/internal/registry/response" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) type ModuleInstaller struct { diff --git a/internal/initwd/module_install_test.go b/internal/initwd/module_install_test.go index 64381db7a8..7dd345e3d0 100644 --- a/internal/initwd/module_install_test.go +++ b/internal/initwd/module_install_test.go @@ -15,7 +15,7 @@ import ( "github.com/hashicorp/terraform/configs/configload" "github.com/hashicorp/terraform/internal/copy" "github.com/hashicorp/terraform/internal/registry" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" _ "github.com/hashicorp/terraform/internal/logging" ) diff --git a/internal/initwd/testing.go b/internal/initwd/testing.go index 0f593becd9..37b0725947 100644 --- a/internal/initwd/testing.go +++ b/internal/initwd/testing.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configload" "github.com/hashicorp/terraform/internal/registry" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // LoadConfigForTests is a convenience wrapper around configload.NewLoaderForTests, diff --git a/internal/legacy/helper/schema/backend.go b/internal/legacy/helper/schema/backend.go index a7f440e026..661e67e239 100644 --- a/internal/legacy/helper/schema/backend.go +++ b/internal/legacy/helper/schema/backend.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/configs/configschema" diff --git a/internal/legacy/helper/schema/shims_test.go b/internal/legacy/helper/schema/shims_test.go index 90e616e638..5796020330 100644 --- a/internal/legacy/helper/schema/shims_test.go +++ b/internal/legacy/helper/schema/shims_test.go @@ -15,8 +15,8 @@ import ( "github.com/hashicorp/terraform/configs/hcl2shim" "github.com/hashicorp/terraform/internal/legacy/helper/hashcode" "github.com/hashicorp/terraform/internal/legacy/terraform" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/internal/legacy/terraform/schemas.go b/internal/legacy/terraform/schemas.go index 0044606536..e4302fb671 100644 --- a/internal/legacy/terraform/schemas.go +++ b/internal/legacy/terraform/schemas.go @@ -7,9 +7,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // Schemas is a container for various kinds of schema that Terraform needs diff --git a/internal/legacy/terraform/state.go b/internal/legacy/terraform/state.go index 95c1e85130..0a7fc9d70b 100644 --- a/internal/legacy/terraform/state.go +++ b/internal/legacy/terraform/state.go @@ -26,8 +26,8 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" "github.com/mitchellh/copystructure" "github.com/zclconf/go-cty/cty" diff --git a/internal/legacy/terraform/version_required.go b/internal/legacy/terraform/version_required.go index 4c9cb34a41..5a0de5b79f 100644 --- a/internal/legacy/terraform/version_required.go +++ b/internal/legacy/terraform/version_required.go @@ -4,7 +4,7 @@ import ( "fmt" "github.com/hashicorp/hcl/v2" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/configs" diff --git a/internal/moduletest/assertion.go b/internal/moduletest/assertion.go index 007772ed6c..1bacbfac92 100644 --- a/internal/moduletest/assertion.go +++ b/internal/moduletest/assertion.go @@ -1,7 +1,7 @@ package moduletest import ( - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Assertion is the description of a single test assertion, whether diff --git a/internal/moduletest/provider.go b/internal/moduletest/provider.go index 05ce3d6025..ea39b0ac89 100644 --- a/internal/moduletest/provider.go +++ b/internal/moduletest/provider.go @@ -12,8 +12,8 @@ import ( "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/repl" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" ) // Provider is an implementation of providers.Interface which we're diff --git a/internal/repl/session.go b/internal/repl/session.go index dabe4fa103..832d070569 100644 --- a/internal/repl/session.go +++ b/internal/repl/session.go @@ -7,8 +7,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" ) // Session represents the state for a single REPL session. diff --git a/tfdiags/config_traversals.go b/internal/tfdiags/config_traversals.go similarity index 100% rename from tfdiags/config_traversals.go rename to internal/tfdiags/config_traversals.go diff --git a/tfdiags/consolidate_warnings.go b/internal/tfdiags/consolidate_warnings.go similarity index 100% rename from tfdiags/consolidate_warnings.go rename to internal/tfdiags/consolidate_warnings.go diff --git a/tfdiags/consolidate_warnings_test.go b/internal/tfdiags/consolidate_warnings_test.go similarity index 100% rename from tfdiags/consolidate_warnings_test.go rename to internal/tfdiags/consolidate_warnings_test.go diff --git a/tfdiags/contextual.go b/internal/tfdiags/contextual.go similarity index 100% rename from tfdiags/contextual.go rename to internal/tfdiags/contextual.go diff --git a/tfdiags/contextual_test.go b/internal/tfdiags/contextual_test.go similarity index 100% rename from tfdiags/contextual_test.go rename to internal/tfdiags/contextual_test.go diff --git a/tfdiags/diagnostic.go b/internal/tfdiags/diagnostic.go similarity index 100% rename from tfdiags/diagnostic.go rename to internal/tfdiags/diagnostic.go diff --git a/tfdiags/diagnostic_base.go b/internal/tfdiags/diagnostic_base.go similarity index 100% rename from tfdiags/diagnostic_base.go rename to internal/tfdiags/diagnostic_base.go diff --git a/tfdiags/diagnostics.go b/internal/tfdiags/diagnostics.go similarity index 100% rename from tfdiags/diagnostics.go rename to internal/tfdiags/diagnostics.go diff --git a/tfdiags/diagnostics_test.go b/internal/tfdiags/diagnostics_test.go similarity index 100% rename from tfdiags/diagnostics_test.go rename to internal/tfdiags/diagnostics_test.go diff --git a/tfdiags/doc.go b/internal/tfdiags/doc.go similarity index 100% rename from tfdiags/doc.go rename to internal/tfdiags/doc.go diff --git a/tfdiags/error.go b/internal/tfdiags/error.go similarity index 100% rename from tfdiags/error.go rename to internal/tfdiags/error.go diff --git a/tfdiags/hcl.go b/internal/tfdiags/hcl.go similarity index 100% rename from tfdiags/hcl.go rename to internal/tfdiags/hcl.go diff --git a/tfdiags/hcl_test.go b/internal/tfdiags/hcl_test.go similarity index 100% rename from tfdiags/hcl_test.go rename to internal/tfdiags/hcl_test.go diff --git a/tfdiags/rpc_friendly.go b/internal/tfdiags/rpc_friendly.go similarity index 100% rename from tfdiags/rpc_friendly.go rename to internal/tfdiags/rpc_friendly.go diff --git a/tfdiags/rpc_friendly_test.go b/internal/tfdiags/rpc_friendly_test.go similarity index 100% rename from tfdiags/rpc_friendly_test.go rename to internal/tfdiags/rpc_friendly_test.go diff --git a/tfdiags/severity_string.go b/internal/tfdiags/severity_string.go similarity index 100% rename from tfdiags/severity_string.go rename to internal/tfdiags/severity_string.go diff --git a/tfdiags/simple_warning.go b/internal/tfdiags/simple_warning.go similarity index 100% rename from tfdiags/simple_warning.go rename to internal/tfdiags/simple_warning.go diff --git a/tfdiags/source_range.go b/internal/tfdiags/source_range.go similarity index 100% rename from tfdiags/source_range.go rename to internal/tfdiags/source_range.go diff --git a/tfdiags/sourceless.go b/internal/tfdiags/sourceless.go similarity index 100% rename from tfdiags/sourceless.go rename to internal/tfdiags/sourceless.go diff --git a/lang/data.go b/lang/data.go index a47a2a32de..fe211398dc 100644 --- a/lang/data.go +++ b/lang/data.go @@ -2,7 +2,7 @@ package lang import ( "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/lang/data_test.go b/lang/data_test.go index 4d9e7b0eea..c41870f802 100644 --- a/lang/data_test.go +++ b/lang/data_test.go @@ -2,7 +2,7 @@ package lang import ( "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/lang/eval.go b/lang/eval.go index f14592a75d..252c144ec1 100644 --- a/lang/eval.go +++ b/lang/eval.go @@ -9,8 +9,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang/blocktoattr" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" ) diff --git a/lang/funcs/defaults.go b/lang/funcs/defaults.go index c1b854be3b..b91ae9395f 100644 --- a/lang/funcs/defaults.go +++ b/lang/funcs/defaults.go @@ -3,7 +3,7 @@ package funcs import ( "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" "github.com/zclconf/go-cty/cty/function" diff --git a/lang/references.go b/lang/references.go index 569251cb8d..b0b37d15f2 100644 --- a/lang/references.go +++ b/lang/references.go @@ -4,8 +4,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang/blocktoattr" - "github.com/hashicorp/terraform/tfdiags" ) // References finds all of the references in the given set of traversals, diff --git a/plans/objchange/compatible_test.go b/plans/objchange/compatible_test.go index 942a477eaa..80fe277816 100644 --- a/plans/objchange/compatible_test.go +++ b/plans/objchange/compatible_test.go @@ -8,7 +8,7 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/configs/configschema" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestAssertObjectCompatible(t *testing.T) { diff --git a/plans/objchange/plan_valid_test.go b/plans/objchange/plan_valid_test.go index 5fca9b5d87..869d797a63 100644 --- a/plans/objchange/plan_valid_test.go +++ b/plans/objchange/plan_valid_test.go @@ -7,7 +7,7 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/configs/configschema" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TestAssertPlanValid(t *testing.T) { diff --git a/plans/planfile/reader.go b/plans/planfile/reader.go index 83b17ae9c0..a0de2721ad 100644 --- a/plans/planfile/reader.go +++ b/plans/planfile/reader.go @@ -8,9 +8,9 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configload" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states/statefile" - "github.com/hashicorp/terraform/tfdiags" ) const tfstateFilename = "tfstate" diff --git a/plans/planfile/tfplan.go b/plans/planfile/tfplan.go index 66fc8141bd..c3d5955781 100644 --- a/plans/planfile/tfplan.go +++ b/plans/planfile/tfplan.go @@ -8,10 +8,10 @@ import ( "google.golang.org/protobuf/proto" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/internal/planproto" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/version" "github.com/zclconf/go-cty/cty" ) diff --git a/plugin/convert/diagnostics.go b/plugin/convert/diagnostics.go index 7eca328887..43824e1b79 100644 --- a/plugin/convert/diagnostics.go +++ b/plugin/convert/diagnostics.go @@ -1,8 +1,8 @@ package convert import ( + "github.com/hashicorp/terraform/internal/tfdiags" proto "github.com/hashicorp/terraform/internal/tfplugin5" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/plugin/convert/diagnostics_test.go b/plugin/convert/diagnostics_test.go index 00c0bf05ec..3f54985dd5 100644 --- a/plugin/convert/diagnostics_test.go +++ b/plugin/convert/diagnostics_test.go @@ -8,8 +8,8 @@ import ( "github.com/google/go-cmp/cmp/cmpopts" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" + "github.com/hashicorp/terraform/internal/tfdiags" proto "github.com/hashicorp/terraform/internal/tfplugin5" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/plugin/grpc_error.go b/plugin/grpc_error.go index 99ce8c8b8d..0f638b7fa4 100644 --- a/plugin/grpc_error.go +++ b/plugin/grpc_error.go @@ -5,7 +5,7 @@ import ( "path" "runtime" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) diff --git a/plugin/grpc_provider_test.go b/plugin/grpc_provider_test.go index b94f947180..9ab7137287 100644 --- a/plugin/grpc_provider_test.go +++ b/plugin/grpc_provider_test.go @@ -8,8 +8,8 @@ import ( "github.com/golang/mock/gomock" "github.com/google/go-cmp/cmp" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" proto "github.com/hashicorp/terraform/internal/tfplugin5" diff --git a/plugin6/convert/diagnostics.go b/plugin6/convert/diagnostics.go index 6d1db136e6..54058533e7 100644 --- a/plugin6/convert/diagnostics.go +++ b/plugin6/convert/diagnostics.go @@ -1,8 +1,8 @@ package convert import ( + "github.com/hashicorp/terraform/internal/tfdiags" proto "github.com/hashicorp/terraform/internal/tfplugin6" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/plugin6/convert/diagnostics_test.go b/plugin6/convert/diagnostics_test.go index 24f269d059..10088a05f5 100644 --- a/plugin6/convert/diagnostics_test.go +++ b/plugin6/convert/diagnostics_test.go @@ -6,8 +6,8 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" + "github.com/hashicorp/terraform/internal/tfdiags" proto "github.com/hashicorp/terraform/internal/tfplugin6" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/plugin6/grpc_error.go b/plugin6/grpc_error.go index 4781d8216d..717c1642bb 100644 --- a/plugin6/grpc_error.go +++ b/plugin6/grpc_error.go @@ -5,7 +5,7 @@ import ( "path" "runtime" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "google.golang.org/grpc/codes" "google.golang.org/grpc/status" ) diff --git a/plugin6/grpc_provider_test.go b/plugin6/grpc_provider_test.go index 2f8e49667f..ce4e9c54a8 100644 --- a/plugin6/grpc_provider_test.go +++ b/plugin6/grpc_provider_test.go @@ -9,8 +9,8 @@ import ( "github.com/google/go-cmp/cmp" "github.com/google/go-cmp/cmp/cmpopts" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" proto "github.com/hashicorp/terraform/internal/tfplugin6" diff --git a/provider_source.go b/provider_source.go index adfcc77739..ccf17dc9f6 100644 --- a/provider_source.go +++ b/provider_source.go @@ -13,7 +13,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/command/cliconfig" "github.com/hashicorp/terraform/internal/getproviders" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // providerSource constructs a provider source based on a combination of the diff --git a/providers/provider.go b/providers/provider.go index 341a255a6c..ad266f567a 100644 --- a/providers/provider.go +++ b/providers/provider.go @@ -4,8 +4,8 @@ import ( "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // Interface represents the set of methods required for a complete resource diff --git a/provisioners/provisioner.go b/provisioners/provisioner.go index e53c88488e..971ad35d78 100644 --- a/provisioners/provisioner.go +++ b/provisioners/provisioner.go @@ -2,7 +2,7 @@ package provisioners import ( "github.com/hashicorp/terraform/configs/configschema" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/states/statefile/diagnostics.go b/states/statefile/diagnostics.go index a6d88ecd58..b45b05ee0b 100644 --- a/states/statefile/diagnostics.go +++ b/states/statefile/diagnostics.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) const invalidFormat = "Invalid state file format" diff --git a/states/statefile/read.go b/states/statefile/read.go index 8abd3be14d..61f8e87d6c 100644 --- a/states/statefile/read.go +++ b/states/statefile/read.go @@ -10,7 +10,7 @@ import ( version "github.com/hashicorp/go-version" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" tfversion "github.com/hashicorp/terraform/version" ) diff --git a/states/statefile/version1.go b/states/statefile/version1.go index 2a5edc01bd..0b82a13e22 100644 --- a/states/statefile/version1.go +++ b/states/statefile/version1.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func readStateV1(src []byte) (*File, tfdiags.Diagnostics) { diff --git a/states/statefile/version2.go b/states/statefile/version2.go index 9f74815ea5..2c5908c37c 100644 --- a/states/statefile/version2.go +++ b/states/statefile/version2.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func readStateV2(src []byte) (*File, tfdiags.Diagnostics) { diff --git a/states/statefile/version3.go b/states/statefile/version3.go index ab6414b0a7..480cae8f4e 100644 --- a/states/statefile/version3.go +++ b/states/statefile/version3.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func readStateV3(src []byte) (*File, tfdiags.Diagnostics) { diff --git a/states/statefile/version3_upgrade.go b/states/statefile/version3_upgrade.go index 29c3eb77bc..a1e3cf2299 100644 --- a/states/statefile/version3_upgrade.go +++ b/states/statefile/version3_upgrade.go @@ -12,8 +12,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) func upgradeStateV3ToV4(old *stateV3) (*stateV4, error) { diff --git a/states/statefile/version4.go b/states/statefile/version4.go index 8d32eb7ad4..41c45dc769 100644 --- a/states/statefile/version4.go +++ b/states/statefile/version4.go @@ -11,8 +11,8 @@ import ( ctyjson "github.com/zclconf/go-cty/cty/json" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) func readStateV4(src []byte) (*File, tfdiags.Diagnostics) { diff --git a/states/statefile/version4_test.go b/states/statefile/version4_test.go index f097a6069c..d71d33734f 100644 --- a/states/statefile/version4_test.go +++ b/states/statefile/version4_test.go @@ -5,7 +5,7 @@ import ( "strings" "testing" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/context.go b/terraform/context.go index f9d7fdd0e0..cbb534cd0f 100644 --- a/terraform/context.go +++ b/terraform/context.go @@ -11,12 +11,12 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/hashicorp/terraform/internal/depsfile" diff --git a/terraform/context_apply_test.go b/terraform/context_apply_test.go index d7d0910c78..0982fbd43a 100644 --- a/terraform/context_apply_test.go +++ b/terraform/context_apply_test.go @@ -22,11 +22,11 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/gocty" ) diff --git a/terraform/context_import.go b/terraform/context_import.go index 4a35c29dc7..91fa8ade3e 100644 --- a/terraform/context_import.go +++ b/terraform/context_import.go @@ -2,8 +2,8 @@ package terraform import ( "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ImportOpts are used as the configuration for Import. diff --git a/terraform/context_input.go b/terraform/context_input.go index 305bae77f3..a875ad8a3b 100644 --- a/terraform/context_input.go +++ b/terraform/context_input.go @@ -11,7 +11,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // Input asks for input to fill unset required arguments in provider diff --git a/terraform/context_plan_test.go b/terraform/context_plan_test.go index 11f3edf897..8e772b6a89 100644 --- a/terraform/context_plan_test.go +++ b/terraform/context_plan_test.go @@ -18,11 +18,11 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/configs/hcl2shim" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) func TestContext2Plan_basic(t *testing.T) { diff --git a/terraform/context_test.go b/terraform/context_test.go index f07ea1058a..1153ab0172 100644 --- a/terraform/context_test.go +++ b/terraform/context_test.go @@ -21,13 +21,13 @@ import ( "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/configs/hcl2shim" "github.com/hashicorp/terraform/internal/depsfile" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/planfile" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" "github.com/hashicorp/terraform/states/statefile" - "github.com/hashicorp/terraform/tfdiags" tfversion "github.com/hashicorp/terraform/version" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/context_validate_test.go b/terraform/context_validate_test.go index e0048d0329..8cc833fa7c 100644 --- a/terraform/context_validate_test.go +++ b/terraform/context_validate_test.go @@ -10,11 +10,11 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) func TestContext2Validate_badCount(t *testing.T) { diff --git a/terraform/eval_context.go b/terraform/eval_context.go index c535568423..634fe7397c 100644 --- a/terraform/eval_context.go +++ b/terraform/eval_context.go @@ -5,12 +5,12 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/eval_context_builtin.go b/terraform/eval_context_builtin.go index a93c70d33b..acf6edd7a4 100644 --- a/terraform/eval_context_builtin.go +++ b/terraform/eval_context_builtin.go @@ -16,8 +16,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/addrs" "github.com/zclconf/go-cty/cty" diff --git a/terraform/eval_context_mock.go b/terraform/eval_context_mock.go index 16b3b0fb1c..a158390de8 100644 --- a/terraform/eval_context_mock.go +++ b/terraform/eval_context_mock.go @@ -6,12 +6,12 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" ) diff --git a/terraform/eval_count.go b/terraform/eval_count.go index 38a41b8d5b..62da234a70 100644 --- a/terraform/eval_count.go +++ b/terraform/eval_count.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/gocty" ) diff --git a/terraform/eval_for_each.go b/terraform/eval_for_each.go index d2be0a2c42..7766de506f 100644 --- a/terraform/eval_for_each.go +++ b/terraform/eval_for_each.go @@ -4,8 +4,8 @@ import ( "fmt" "github.com/hashicorp/hcl/v2" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/eval_for_each_test.go b/terraform/eval_for_each_test.go index 2f71566373..136045f29d 100644 --- a/terraform/eval_for_each_test.go +++ b/terraform/eval_for_each_test.go @@ -8,7 +8,7 @@ import ( "github.com/davecgh/go-spew/spew" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hcltest" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/eval_variable.go b/terraform/eval_variable.go index 34669f9660..70dfa6168a 100644 --- a/terraform/eval_variable.go +++ b/terraform/eval_variable.go @@ -7,7 +7,7 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" ) diff --git a/terraform/evaluate.go b/terraform/evaluate.go index d6d47585bc..a19c8af8ac 100644 --- a/terraform/evaluate.go +++ b/terraform/evaluate.go @@ -16,10 +16,10 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // Evaluator provides the necessary contextual data for evaluating expressions diff --git a/terraform/evaluate_test.go b/terraform/evaluate_test.go index 8c57c8e65c..6656d20913 100644 --- a/terraform/evaluate_test.go +++ b/terraform/evaluate_test.go @@ -10,9 +10,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) func TestEvaluatorGetTerraformAttr(t *testing.T) { diff --git a/terraform/evaluate_valid.go b/terraform/evaluate_valid.go index 3a8323ae56..99543728ba 100644 --- a/terraform/evaluate_valid.go +++ b/terraform/evaluate_valid.go @@ -9,7 +9,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/didyoumean" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // StaticValidateReferences checks the given references against schemas and diff --git a/terraform/execute.go b/terraform/execute.go index 6d038d9d48..8c3a6fe15e 100644 --- a/terraform/execute.go +++ b/terraform/execute.go @@ -1,6 +1,6 @@ package terraform -import "github.com/hashicorp/terraform/tfdiags" +import "github.com/hashicorp/terraform/internal/tfdiags" // GraphNodeExecutable is the interface that graph nodes must implement to // enable execution. diff --git a/terraform/graph.go b/terraform/graph.go index 03d6edb1aa..cab316f59a 100644 --- a/terraform/graph.go +++ b/terraform/graph.go @@ -4,7 +4,7 @@ import ( "log" "strings" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/addrs" diff --git a/terraform/graph_builder.go b/terraform/graph_builder.go index 0f740fad9c..3b6ee322c2 100644 --- a/terraform/graph_builder.go +++ b/terraform/graph_builder.go @@ -5,7 +5,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/logging" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // GraphBuilder is an interface that can be implemented and used with diff --git a/terraform/graph_builder_apply.go b/terraform/graph_builder_apply.go index 1a702e3729..314a915c8f 100644 --- a/terraform/graph_builder_apply.go +++ b/terraform/graph_builder_apply.go @@ -4,9 +4,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ApplyGraphBuilder implements GraphBuilder and is responsible for building diff --git a/terraform/graph_builder_destroy_plan.go b/terraform/graph_builder_destroy_plan.go index 413b6a6863..f66fd61edc 100644 --- a/terraform/graph_builder_destroy_plan.go +++ b/terraform/graph_builder_destroy_plan.go @@ -4,8 +4,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // DestroyPlanGraphBuilder implements GraphBuilder and is responsible for diff --git a/terraform/graph_builder_eval.go b/terraform/graph_builder_eval.go index ef17d5d48f..c0640e3054 100644 --- a/terraform/graph_builder_eval.go +++ b/terraform/graph_builder_eval.go @@ -4,8 +4,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // EvalGraphBuilder implements GraphBuilder and constructs a graph suitable diff --git a/terraform/graph_builder_import.go b/terraform/graph_builder_import.go index 1aa1fe1801..2aa2a3359c 100644 --- a/terraform/graph_builder_import.go +++ b/terraform/graph_builder_import.go @@ -4,7 +4,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // ImportGraphBuilder implements GraphBuilder and is responsible for building diff --git a/terraform/graph_builder_plan.go b/terraform/graph_builder_plan.go index 7b6585ae6b..8c8926a0ae 100644 --- a/terraform/graph_builder_plan.go +++ b/terraform/graph_builder_plan.go @@ -6,8 +6,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // PlanGraphBuilder implements GraphBuilder and is responsible for building diff --git a/terraform/graph_walk.go b/terraform/graph_walk.go index 4ede235130..3ffe471a88 100644 --- a/terraform/graph_walk.go +++ b/terraform/graph_walk.go @@ -2,7 +2,7 @@ package terraform import ( "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // GraphWalker is an interface that can be implemented that when used diff --git a/terraform/graph_walk_context.go b/terraform/graph_walk_context.go index d7b24a1821..cfead392ed 100644 --- a/terraform/graph_walk_context.go +++ b/terraform/graph_walk_context.go @@ -9,11 +9,11 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/instances" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ContextGraphWalker is the GraphWalker implementation used with the diff --git a/terraform/node_count_boundary.go b/terraform/node_count_boundary.go index 2e972ff216..f191389486 100644 --- a/terraform/node_count_boundary.go +++ b/terraform/node_count_boundary.go @@ -6,7 +6,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // NodeCountBoundary fixes up any transitions between "each modes" in objects diff --git a/terraform/node_data_destroy.go b/terraform/node_data_destroy.go index 14c06516b4..0e81bb9c45 100644 --- a/terraform/node_data_destroy.go +++ b/terraform/node_data_destroy.go @@ -3,7 +3,7 @@ package terraform import ( "log" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // NodeDestroyableDataResourceInstance represents a resource that is "destroyable": diff --git a/terraform/node_local.go b/terraform/node_local.go index a59f922939..4cea5c3552 100644 --- a/terraform/node_local.go +++ b/terraform/node_local.go @@ -8,8 +8,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_module_expand.go b/terraform/node_module_expand.go index fd7d4015fe..31f86fee76 100644 --- a/terraform/node_module_expand.go +++ b/terraform/node_module_expand.go @@ -6,8 +6,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" ) type ConcreteModuleNodeFunc func(n *nodeExpandModule) dag.Vertex diff --git a/terraform/node_module_variable.go b/terraform/node_module_variable.go index 35fd632b23..fe94d9b4be 100644 --- a/terraform/node_module_variable.go +++ b/terraform/node_module_variable.go @@ -9,8 +9,8 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/instances" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/zclconf/go-cty/cty/convert" ) diff --git a/terraform/node_output.go b/terraform/node_output.go index 4d2e9a4a8a..ec36a63946 100644 --- a/terraform/node_output.go +++ b/terraform/node_output.go @@ -8,10 +8,10 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_provider.go b/terraform/node_provider.go index 5b06a25a61..6f2f74033d 100644 --- a/terraform/node_provider.go +++ b/terraform/node_provider.go @@ -6,8 +6,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_provider_eval.go b/terraform/node_provider_eval.go index a89583cff5..fba47ddb96 100644 --- a/terraform/node_provider_eval.go +++ b/terraform/node_provider_eval.go @@ -1,6 +1,6 @@ package terraform -import "github.com/hashicorp/terraform/tfdiags" +import "github.com/hashicorp/terraform/internal/tfdiags" // NodeEvalableProvider represents a provider during an "eval" walk. // This special provider node type just initializes a provider and diff --git a/terraform/node_provider_test.go b/terraform/node_provider_test.go index 4eafe49fa3..71ec17781e 100644 --- a/terraform/node_provider_test.go +++ b/terraform/node_provider_test.go @@ -9,8 +9,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_resource_abstract.go b/terraform/node_resource_abstract.go index defdca2110..76b56cb2c1 100644 --- a/terraform/node_resource_abstract.go +++ b/terraform/node_resource_abstract.go @@ -8,9 +8,9 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ConcreteResourceNodeFunc is a callback type used to convert an diff --git a/terraform/node_resource_abstract_instance.go b/terraform/node_resource_abstract_instance.go index 01fd26e226..dcb085e7af 100644 --- a/terraform/node_resource_abstract_instance.go +++ b/terraform/node_resource_abstract_instance.go @@ -9,12 +9,12 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/objchange" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_resource_apply.go b/terraform/node_resource_apply.go index 34497bbd72..4b8e7924f8 100644 --- a/terraform/node_resource_apply.go +++ b/terraform/node_resource_apply.go @@ -5,8 +5,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" ) // nodeExpandApplyableResource handles the first layer of resource diff --git a/terraform/node_resource_apply_instance.go b/terraform/node_resource_apply_instance.go index 8db54970bf..a4bb0fc66e 100644 --- a/terraform/node_resource_apply_instance.go +++ b/terraform/node_resource_apply_instance.go @@ -6,10 +6,10 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/plans/objchange" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // NodeApplyableResourceInstance represents a resource instance that is diff --git a/terraform/node_resource_destroy.go b/terraform/node_resource_destroy.go index 1027b67f35..4abd05a42b 100644 --- a/terraform/node_resource_destroy.go +++ b/terraform/node_resource_destroy.go @@ -4,8 +4,8 @@ import ( "fmt" "log" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" diff --git a/terraform/node_resource_destroy_deposed.go b/terraform/node_resource_destroy_deposed.go index 459a525862..e152f335ed 100644 --- a/terraform/node_resource_destroy_deposed.go +++ b/terraform/node_resource_destroy_deposed.go @@ -6,9 +6,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ConcreteResourceInstanceDeposedNodeFunc is a callback type used to convert diff --git a/terraform/node_resource_plan.go b/terraform/node_resource_plan.go index d3c99fc1ad..0fab7b6b51 100644 --- a/terraform/node_resource_plan.go +++ b/terraform/node_resource_plan.go @@ -7,8 +7,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // nodeExpandPlannableResource handles the first layer of resource diff --git a/terraform/node_resource_plan_destroy.go b/terraform/node_resource_plan_destroy.go index bb731d8c4f..098ff09f17 100644 --- a/terraform/node_resource_plan_destroy.go +++ b/terraform/node_resource_plan_destroy.go @@ -2,9 +2,9 @@ package terraform import ( "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // NodePlanDestroyableResourceInstance represents a resource that is ready diff --git a/terraform/node_resource_plan_instance.go b/terraform/node_resource_plan_instance.go index e13f5fe951..aca716d5c2 100644 --- a/terraform/node_resource_plan_instance.go +++ b/terraform/node_resource_plan_instance.go @@ -5,9 +5,9 @@ import ( "log" "sort" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/addrs" ) diff --git a/terraform/node_resource_plan_orphan.go b/terraform/node_resource_plan_orphan.go index 144226fb96..33c3ccf206 100644 --- a/terraform/node_resource_plan_orphan.go +++ b/terraform/node_resource_plan_orphan.go @@ -5,9 +5,9 @@ import ( "log" "github.com/hashicorp/terraform/addrs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // NodePlannableResourceInstanceOrphan represents a resource that is "applyable": diff --git a/terraform/node_resource_validate.go b/terraform/node_resource_validate.go index 13d5997ea4..1c9d85046e 100644 --- a/terraform/node_resource_validate.go +++ b/terraform/node_resource_validate.go @@ -8,9 +8,9 @@ import ( "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" "github.com/hashicorp/terraform/internal/didyoumean" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_resource_validate_test.go b/terraform/node_resource_validate_test.go index 3d63bf222f..cbd5fdd58b 100644 --- a/terraform/node_resource_validate_test.go +++ b/terraform/node_resource_validate_test.go @@ -10,9 +10,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/provisioners" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/node_root_variable.go b/terraform/node_root_variable.go index 36edf983eb..04586043dc 100644 --- a/terraform/node_root_variable.go +++ b/terraform/node_root_variable.go @@ -4,7 +4,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // NodeRootVariable represents a root variable input. diff --git a/terraform/schemas.go b/terraform/schemas.go index 017856ef53..c0bfd4de30 100644 --- a/terraform/schemas.go +++ b/terraform/schemas.go @@ -7,9 +7,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // Schemas is a container for various kinds of schema that Terraform needs diff --git a/terraform/transform_diff.go b/terraform/transform_diff.go index 93950f2849..351789d0b2 100644 --- a/terraform/transform_diff.go +++ b/terraform/transform_diff.go @@ -5,9 +5,9 @@ import ( "log" "github.com/hashicorp/terraform/internal/dag" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/plans" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // DiffTransformer is a GraphTransformer that adds graph nodes representing diff --git a/terraform/transform_import_state.go b/terraform/transform_import_state.go index f5e3d6a487..db3a7d5920 100644 --- a/terraform/transform_import_state.go +++ b/terraform/transform_import_state.go @@ -6,9 +6,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" ) // ImportStateTransformer is a GraphTransformer that adds nodes to the diff --git a/terraform/transform_module_variable.go b/terraform/transform_module_variable.go index 99a86c01d9..d9a08772d0 100644 --- a/terraform/transform_module_variable.go +++ b/terraform/transform_module_variable.go @@ -5,7 +5,7 @@ import ( "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/hashicorp/terraform/addrs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/zclconf/go-cty/cty" "github.com/hashicorp/hcl/v2" diff --git a/terraform/transform_provider.go b/terraform/transform_provider.go index fa89655dd9..8fe9628c8b 100644 --- a/terraform/transform_provider.go +++ b/terraform/transform_provider.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs" "github.com/hashicorp/terraform/internal/dag" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) func TransformProviders(providers []string, concrete ConcreteProviderNodeFunc, config *configs.Config) GraphTransformer { diff --git a/terraform/upgrade_resource_state.go b/terraform/upgrade_resource_state.go index 924b79ccc8..eab2081c40 100644 --- a/terraform/upgrade_resource_state.go +++ b/terraform/upgrade_resource_state.go @@ -7,9 +7,9 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/providers" "github.com/hashicorp/terraform/states" - "github.com/hashicorp/terraform/tfdiags" "github.com/zclconf/go-cty/cty" ) diff --git a/terraform/validate_selfref.go b/terraform/validate_selfref.go index d00b1975be..1f2826331d 100644 --- a/terraform/validate_selfref.go +++ b/terraform/validate_selfref.go @@ -7,8 +7,8 @@ import ( "github.com/hashicorp/terraform/addrs" "github.com/hashicorp/terraform/configs/configschema" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/lang" - "github.com/hashicorp/terraform/tfdiags" ) // validateSelfRef checks to ensure that expressions within a particular diff --git a/terraform/variables.go b/terraform/variables.go index 14f6a3ccf4..1ecd9f97c0 100644 --- a/terraform/variables.go +++ b/terraform/variables.go @@ -8,7 +8,7 @@ import ( "github.com/zclconf/go-cty/cty/convert" "github.com/hashicorp/terraform/configs" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" ) // InputValue represents a value for a variable in the root module, provided diff --git a/terraform/variables_test.go b/terraform/variables_test.go index 320a6740da..41decbae2a 100644 --- a/terraform/variables_test.go +++ b/terraform/variables_test.go @@ -4,7 +4,7 @@ import ( "testing" "github.com/davecgh/go-spew/spew" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/go-test/deep" "github.com/zclconf/go-cty/cty" diff --git a/terraform/version_required.go b/terraform/version_required.go index 4c9cb34a41..5a0de5b79f 100644 --- a/terraform/version_required.go +++ b/terraform/version_required.go @@ -4,7 +4,7 @@ import ( "fmt" "github.com/hashicorp/hcl/v2" - "github.com/hashicorp/terraform/tfdiags" + "github.com/hashicorp/terraform/internal/tfdiags" "github.com/hashicorp/terraform/configs" diff --git a/tools/terraform-bundle/package.go b/tools/terraform-bundle/package.go index 8a83c69a7b..45bddbbf42 100644 --- a/tools/terraform-bundle/package.go +++ b/tools/terraform-bundle/package.go @@ -20,8 +20,8 @@ import ( "github.com/hashicorp/terraform/internal/getproviders" "github.com/hashicorp/terraform/internal/httpclient" "github.com/hashicorp/terraform/internal/providercache" + "github.com/hashicorp/terraform/internal/tfdiags" discovery "github.com/hashicorp/terraform/plugin/discovery" - "github.com/hashicorp/terraform/tfdiags" "github.com/hashicorp/terraform/version" "github.com/mitchellh/cli" )