-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Add case of valueUnknown in configId pre-computing #8853
Add case of valueUnknown in configId pre-computing #8853
Conversation
Hello! I am a robot. It looks like you are a: Community Contributor @roaks3, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look. You can help make sure that review is quick by doing a self-review and by running impacted tests locally. |
@oshiro3 the logic here makes sense to me, but I'd like to confirm that this is in fact the behavior of the API for all 3 of these fields (and it results in an error). One thing that might help is tests, and I'm not clear on where you found trouble. Is it possible to recreate the config that failed in the issue, and make sure it succeeds? |
@roaks3
|
Sorry, I'm not exactly following. Could we use your example (ie. |
Sorry for the delay.
Test may be incomplete in this regard, but I think the code I put in one previous comment at least does the behavior I expect. |
Basically I think we need to include a test for this behavior, and I believe that this could be accomplished without a null_resource. I would try something like this if you are stuck on that:
|
…nto fix_endpoints_precomputed_config_id
I have created a test based on your comment, I am not sure I understand the behavior of the tag_key resource well, but does it become a test that fully meets the specification? |
@roaks3 |
When certain attributes such as protoc_output_base64 are changed, config_id is pre-compute, but if these attributes are (known-after-apply) at plan time and there is no diff as a result of apply, the plan result will not match and
Error: Provider produced inconsistent final plan
.Therefore, if those attributes have been changed and their values are non-deterministic, config_id is also calculated at apply time.
I was going to add a test, but I couldn't figure out how to do it without using an external provider such as null_resource for certain attributes, so I didn't implement it.
If there is a better way, please let me know.
issue: hashicorp/terraform-provider-google#11776
Release Note Template for Downstream PRs (will be copied)