-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Partly rollback changes from #11321 to fix an alias_ip_range
bug
#12180
base: main
Are you sure you want to change the base?
Conversation
Hello! I am a robot. Tests will require approval from a repository maintainer to run. @shuyama1, 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. |
alias_ip_range
bug
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 1048 Click here to see the affected service packages
Action takenFound 3 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
🟢 Tests passed during RECORDING mode: 🟢 No issues found for passed tests after REPLAYING rerun. 🔴 Tests failed during RECORDING mode: 🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR. |
Something changed with allow_stopping_for_update since this was merged i'm guessing.
Putting it in as VerifyIgnore. |
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 1058 Click here to see the affected service packages
Action takenFound 26 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
🟢 Tests passed during RECORDING mode: 🟢 No issues found for passed tests after REPLAYING rerun. 🟢 All tests passed! |
@GoogleCloudPlatform/terraform-team @shuyama1 This PR has been waiting for review for 1 week. Please take a look! Use the label |
Sorry for the delay on review. Taking a look now! |
/gcbrun |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 1059 Click here to see the affected service packages
🟢 All tests passed! View the build log |
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.
The rollback seems reasonable to me, as the original fix is potentially a breaking change(?) since it changes the order of alias_ip_range
blocks in state. The change has led to another issue that breaks existing configs, as discussed in hashicorp/terraform-provider-google#19765.
I'm inviting @melinath, the reviewer of the original PR #11321, to weigh in on this rollback, to ensure I haven’t overlooked any potential issues that could impact users.
I believe this should be resolved by #12208. If you rebase your PR, the check should pass on the next run. |
yeah, sorting by config order assumes that all the blocks are explicitly defined in the config; since the API can add computed values into the mix that we can't tie back to a specific block in the config, sorting by config order is insufficient. Rolling this back seems reasonable. |
What are the problems besides the /32 generating a random value? That seems like it would be relatively easy to compensate for. (But I may be missing something.) |
The "/32" isn't that big of an issue. I already wrote and tested an algorithm that solved this issue but the big problems start when a user adds a new Overall a very edge-case heavy implementation and it seems like too much of a hustle to implement this kind of logic for a field that's out of the ordinary when it comes to functionality for Google Edit: just to clarify. The order of the blocks in code reflects the order of the IP's saved in state. So when added in the middle (not at the end) this also adds the IP in the middle of an array making it harder to compare against API output. This also enables weird behaviour when the first IP is deleted. All the other shift one place up. This also isn't that big of a problem by it self but add the unknown values to it and you've got a headache of an implementation 😄 Edit: Rebased branch, this "api limitation" was forwarded to network API team as well |
ea7b60d
to
f25589e
Compare
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 1060 Click here to see the affected service packages
🟢 All tests passed! View the build log |
It sounds like there may be some issues with how the "sort by config order" helper functions work that would be nice to resolve (alongside the /32 issue). I'm not sure I have a good feel for whether the current behavior or the previous permadiff is worse; I don't really want us to back out this behavior just to introduce the old bug. FWIW it should be possible to do a diff suppress with CustomizeDiff, since that operates on the entire resource at once. (Though it looks like it might have some trouble with known-after-apply values...) @shuyama1 what's your take? |
@shuyama1 This PR has been waiting for review for 3 weekdays. Please take a look! Use the label |
rollback from #11321
closes hashicorp/terraform-provider-google#19765 (more context in the comments of this issue)
This issue will get reintroduced hashicorp/terraform-provider-google#12286
This cannot be easily fixed without introducing new edge cases or crazy overhead for this field hence the rollback. The problems are:
Overall, i'd say that we should accept the fact that the array of alias_ip ranges get's cleared in between requests and treat it as an API limitation until it gets fixed. I don't think we should build additional UX features on top of an API method that doesn't work according to Google's standards (it should support deletion and creation at the same time)
partly rollback because i'm leaving the tests introduced in the previous PR. They could be useful if this gets fixed in the future
Release Note Template for Downstream PRs (will be copied)
See Write release notes for guidance.