Stronger preconditions before calling wait_for_commit - expect primary unanimity#7705
Merged
achamayou merged 2 commits intomicrosoft:mainfrom Mar 5, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR strengthens test preconditions around elections by requiring primary unanimity before proceeding to commit synchronisation, addressing flaky “Multiple commit values” failures seen after leadership changes/suspensions.
Changes:
- Add a
wait_for_primary_unanimity()barrier afterforce_become_primary()transitions, ensuring all nodes converge on the same primary. - Replace
wait_for_new_primary_in(...)withwait_for_primary_unanimity()in snapshot-selection tests before callingwait_for_node_commit_sync().
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| tests/partitions_test.py | After forcing a new primary, wait for all nodes to agree on the primary before continuing. |
| tests/e2e_operations.py | After resuming suspended nodes, wait for primary unanimity before commit sync to reduce election/commit skew flakiness. |
maxtropets
approved these changes
Mar 5, 2026
achamayou
approved these changes
Mar 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See explanatory comment here: #7702 (comment)
Should resolve #7702 and #7687.