Skip to content
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

don't compare plan marks for missing values #32892

Merged
merged 1 commit into from
Mar 28, 2023

Conversation

jbardin
Copy link
Member

@jbardin jbardin commented Mar 20, 2023

If a resource has a change in marks from the prior state, we need to notify the user that an update is going to be necessary to at least store that new value in the state. If the provider however returns a prior state value in lieu of a new config value, we need to be sure to filter any new marks for comparison as well. The comparison of the prior marks and new marks must take into account whether those new marks could even be applied, and if the value is unchanged, the new marks may be completely irrelevant.

Fixes #32864

@jbardin jbardin added the 1.4-backport If you add this label to a PR before merging, backport-assistant will open a new PR once merged label Mar 20, 2023
@jbardin jbardin requested a review from a team March 20, 2023 20:35
@jbardin jbardin force-pushed the jbardin/update-missing-sensitive branch from 25bdd13 to 22adce9 Compare March 20, 2023 20:38
If a resource has a change in marks from the prior state, we need to
notify the user that an update is going to be necessary to at least
store that new value in the state. If the provider however returns the
prior state value in lieu of a new config value, we need to be sure to
filter any new marks for comparison as well. The comparison of the prior
marks and new marks must take into account whether those new marks could
even be applied, because if the value is unchanged the new marks may be
completely irrelevant.
@jbardin jbardin force-pushed the jbardin/update-missing-sensitive branch from 22adce9 to 81b74cd Compare March 28, 2023 19:55
@jbardin jbardin merged commit 31f278b into main Mar 28, 2023
@jbardin jbardin deleted the jbardin/update-missing-sensitive branch March 28, 2023 20:01
@github-actions
Copy link

Reminder for the merging maintainer: if this is a user-visible change, please update the changelog on the appropriate release branch.

@github-actions
Copy link

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
1.4-backport If you add this label to a PR before merging, backport-assistant will open a new PR once merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sensitive variable with null default causes unnecessary plan to update in-place
2 participants