Reduce flakiness in block checks#268
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR aims to reduce CI flakiness in network progress checks by (a) making the block-height check sample nodes “at the same time” and (b) making the blocks-rolling check rely on forward observation rather than historical samples, and it also introduces a “network bootstrap” signal to avoid single-node startup deadlocks around doublesign protection.
Changes:
- Add
NETWORK_BOOTSTRAPplumbing (Go → Docker env →run_sonic.sh) to conditionally disableDoublesignProtectiononly when bootstrapping a brand-new single-validator network. - Refactor
blocksRollingto observe progress over a time window (with updated tests). - Read block heights concurrently in
blockHeightchecker (with updated tests) to avoid false lag detection due to sequential sampling.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| scripts/run_sonic.sh | Gate DoublesignProtection disabling behind NETWORK_BOOTSTRAP for single-validator bootstrap. |
| scenarios/rules_upgrades/allegro_to_brio_mixed_versions.yml | Update scenario description and remove the v2.1.5 node step. |
| driver/norma/run.go | Adjust node log dumping output formatting and severity. |
| driver/node/opera.go | Add NetworkBootstrap to node config and pass it to the container env as NETWORK_BOOTSTRAP. |
| driver/network/local/local.go | Infer and set NetworkBootstrap when creating nodes. |
| driver/checking/blocks_rolling.go | Replace historical sliding-window logic with forward observation window logic. |
| driver/checking/blocks_rolling_test.go | Rewrite tests to match the new forward-observation behavior. |
| driver/checking/block_height.go | Fetch block heights concurrently to reduce skew between node samples. |
| driver/checking/block_height_test.go | Update mocks/expectations for concurrent RPC calls; add a genesis-within-slack test. |
LuisPH3
previously approved these changes
Jul 23, 2026
LuisPH3
approved these changes
Jul 23, 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.
This PR refactors the blocks rolling and block height checks to be less flaky on CI infrastructure. These changes surfaced an issue the norma configuration when only a single node is present in the network.