-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
fix invalid provider configuration #5609
Conversation
I have triggered VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccDatasourceGoogleServiceNetworkingPeeredDnsDomain_basic|TestAccApigeeEnvironmentIamBindingGenerated|TestAccApigeeEnvironmentIamMemberGenerated|TestAccApigeeEnvironmentIamPolicyGenerated|TestAccCloudbuildWorkerPool_basic|TestAccContainerNodePool_withInvalidUpgradeSettings|TestAccServiceNetworkingPeeredDNSDomain_basic You can view the result here: https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=241919 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is passing a computed value to a provider invalid? We have seen similar issues trying to set up the Kubernetes provider with input from a GKE cluster (or something like that) but it seems like it generally works if you create the GKE cluster first so the computed values aren't unknown.
Is there a possibility in the future of the TF dependency graph including providers so that this workflow can be possible?
@slevenick I checked in on this because I started questioning myself, it looks like Kubernetes has implemented a way to defer their provider initialization in order to handle this, although, it sounds like this is not the recommended approach as there can be intermittent issues with it. As for future, I see this issue open in core: hashicorp/terraform#4149 |
* fix invalid provider configuration * fix lint errors
* fix invalid provider configuration * fix lint errors
* fix invalid provider configuration * fix lint errors
Fixes hashicorp/terraform-provider-google#9237
Basically, passing in a computed value to the provider definition is illegal, so i had to rip out all the setup configuration and just do that in the SDK, before the tests were run.
If this PR is for Terraform, I acknowledge that I have:
make test
andmake lint
to ensure it passes unit and linter tests.Release Note Template for Downstream PRs (will be copied)