-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error diagnostics are not surfaced in the CLI when default is used for non-computed attribute #176
Labels
bug
Something isn't working
Comments
bendbennett
added a commit
that referenced
this issue
Jul 13, 2023
…agnostics in the GetProviderSchemaResponse (#176)
bendbennett
added a commit
that referenced
this issue
Jul 13, 2023
bendbennett
added a commit
that referenced
this issue
Jul 14, 2023
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Module version
Relevant provider source code
The
attr_settings
attribute has been incorrectly defined as it is using aDefault
, but it has not been specified asComputed
.Terraform Configuration Files
Debug Output
https://gist.github.com/bendbennett/8df62591b5f7d83a3b60ba2414b7cc26
The lines of interest are:
2023-07-12T14:21:44.225+0100 [TRACE] provider.terraform-provider-playground: Getting provider schema: tf_mux_provider=*schema.GRPCProviderServer tf_req_id=9ac1ac91-3f8a-68a7-0919-7bc2d9ea80de tf_rpc=GetProviderSchema @caller=/Users/bdb/go/pkg/mod/github.com/hashicorp/terraform-plugin-sdk/v2@v2.26.1/helper/schema/grpc_provider.go:70 @module=sdk.helper_schema tf_provider_addr=registry.terraform.io/bendbennett/playground timestamp=2023-07-12T14:21:44.225+0100 2023-07-12T14:21:44.225+0100 [TRACE] provider.terraform-provider-playground: Received downstream response: tf_provider_addr=registry.terraform.io/bendbennett/playground tf_rpc=GetProviderSchema @module=sdk.proto diagnostic_warning_count=0 tf_proto_version=5.3 tf_req_duration_ms=1 tf_req_id=9ac1ac91-3f8a-68a7-0919-7bc2d9ea80de @caller=/Users/bdb/go/pkg/mod/github.com/hashicorp/terraform-plugin-go@v0.17.0/tfprotov5/internal/tf5serverlogging/downstream_request.go:40 diagnostic_error_count=0 timestamp=2023-07-12T14:21:44.225+0100
Specifically,
diagnostic_error_count=0
.Running a debugger, it can be seen that the relevant diagnostic is added in (*Server).ResourceSchemas().
Expected Behavior
CLI surfaces diagnostic relating to a default being using on an attribute that is not computed:
Actual Behavior
The CLI displays the following message:
Steps to Reproduce
The text was updated successfully, but these errors were encountered: