Skip to content

Fix TestEpochRebroadcastsEmptyVoteAfterBlockProposalReceived Flake #419

Merged
yacovm merged 6 commits into
mainfrom
flake-rebroadcast
Jun 22, 2026
Merged

Fix TestEpochRebroadcastsEmptyVoteAfterBlockProposalReceived Flake #419
yacovm merged 6 commits into
mainfrom
flake-rebroadcast

Conversation

@samliok

@samliok samliok commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@samliok samliok force-pushed the flake-rebroadcast branch from 755fd1b to 1a593f8 Compare June 22, 2026 18:21
Comment thread simplex/epoch_failover_test.go Outdated
samliok added 3 commits June 22, 2026 15:45
A single time advance can produce duplicate empty-vote broadcasts: the
proposal-timeout vote and the timeout-handler's rebroadcast on the same
tick. Two tests assumed exactly one empty vote would be observed.

- waitForEmptyVote now drains duplicate rebroadcasts before returning so
  callers' require.Len(comm.emptyVotes, 0) is not racy.
- TestEpochNoFinalizationAfterEmptyVote now tolerates duplicate empty
  votes before the notarization instead of asserting a fixed position.
Forming the empty notarization advances the node to round 4, where it is
the leader and asynchronously proposes and persists a round 4 block. That
trailing block record races with the test's wal.ReadAll(), so the empty
vote and notarization are not reliably the last two records.

Locate the empty vote and empty notarization records by type instead of
assuming fixed positions at the end of the WAL.
…l race

This test reads the WAL assuming the round 4 block proposal is the last
record, but that proposal is persisted asynchronously after the empty
notarization advances the node to round 4. Wait for the proposal to be
persisted (AssertBlockProposal) before the positional read so it is
deterministically present.
@samliok samliok changed the title Flake TestEpochRebroadcastsEmptyVoteAfterBlockProposalReceived Flake Fix TestEpochRebroadcastsEmptyVoteAfterBlockProposalReceived Flake Jun 22, 2026
@yacovm yacovm merged commit 6f4d149 into main Jun 22, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants