Conversation
muXxer
approved these changes
May 6, 2026
Member
thibault-martinez
left a comment
There was a problem hiding this comment.
Isn't this PR supposed to unignore test_mainnet_config if it's closing the issue?
piotrm50
commented
May 7, 2026
… and align epoch durations Use epoch_store.get_chain() instead of get_chain_identifier().chain() when creating AuthorityCapabilitiesV1. In test clusters using with_chain_override, the ChainIdentifier is derived from the genesis digest which doesn't match known chains, causing chain() to return Chain::Unknown. This produced a protocol config digest mismatch in get_validators_supporting_protocol_version, triggering the "Eligible validators weight 0" fallback on every epoch change. Also align simtest epoch durations with upstream values (10s instead of 1-5s) to give the surfer enough transaction windows between epoch transitions. Closes #11438
e934789 to
ed70c69
Compare
thibault-martinez
approved these changes
May 7, 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.
Description of change
Fix protocol config digest mismatch in capability notifications when using
with_chain_overridein tests, and align simtest epoch durations with upstream.Chain mismatch bug: When creating
AuthorityCapabilitiesV1, the code usedepoch_store.get_chain_identifier().chain()to determine the chain. In test clusters usingwith_chain_override(Chain::Mainnet), theChainIdentifieris derived from the genesis checkpoint digest, which doesn't match known chain digests — so.chain()returnsChain::Unknown. Meanwhile, the epoch store's protocol config is computed with the correctChain::Mainnetfrom the override. This causedget_validators_supporting_protocol_versionto always find 0 matching validators (different chain → different protocol config → different digest), triggering the "Eligible validators weight 0" fallback on every epoch change.Fix: Use
epoch_store.get_chain()which returns the authoritative chain value the epoch store was configured with. In production, this is identical toget_chain_identifier().chain()since the genesis digest matches the known chain. In tests with chain override, it correctly returns the override chain.Epoch duration alignment: Several simtests had shorter epoch durations (1-5s) than upstream (10s). With short epochs and ~15s epoch transitions, the network spends most of its time in transition, leaving the surfer too few transaction windows. This caused flaky failures where all surfer transactions hit epoch boundaries.
Links to any relevant issues
Closes #11438
How the change has been tested
MSIM_TEST_SEED=1778094833170on Linux x86_641778097890094now passes