Skip to content

boole-convergence polish: gating docs, startup fork validation, spectest bound (#2968 items 4, 6, 7) - #2973

Open
momosh-ssv wants to merge 3 commits into
integration/boole-convergencefrom
fix/2968-cleanups
Open

boole-convergence polish: gating docs, startup fork validation, spectest bound (#2968 items 4, 6, 7)#2973
momosh-ssv wants to merge 3 commits into
integration/boole-convergencefrom
fix/2968-cleanups

Conversation

@momosh-ssv

Copy link
Copy Markdown
Contributor

Items 4, 6 and 7 of #2968, one commit each:

  • Item 4 (docs only) — the BooleFork() gate on the legacy Alan RoleAggregator/RoleSyncCommitteeContribution runners is now documented as a deliberate share-add-time snapshot: the cross-population asymmetry is bounded to the Boole subsequent window (SlotsPerEpoch + booleSubsequentWindowLateSlots; 34 slots on mainnet), affects only already-decided pre-fork stragglers, and the runners retire with the Alan topics. Decision recorded on the issue: not worth restructuring the one-shot runner-map construction to slot-gate a dormant path.
  • Item 6Network.Validate(), called right after the Network is assembled at startup: hard error when a scheduled forks.boole epoch would overflow FirstSlotAtEpoch (or SlotsPerEpoch is zero — the review caught that the overflow guard alone would panic on that same malformed-config class); operator-actionable warning when Boole is scheduled but NextDomainType == DomainType (the exact signature of a forgotten next_domain_type, which would "activate" the fork with zero observable domain change).
  • Item 7 — the alan-spec error-code remap bound is derived from TimeoutInstanceErrorCode + 2 (= 72, the real v1.2.2 maximum) instead of the disconnected magic 79, so a spec bump adding codes can't silently widen the remap. Builds under -tags alan_spec (that leg doesn't run in normal CI).

The BooleFork() gate on the RoleAggregator/RoleSyncCommitteeContribution
runners is a deliberate share-add-time snapshot: the resulting
cross-population asymmetry is bounded to the Boole subsequent window
(SlotsPerEpoch + booleSubsequentWindowLateSlots; 34 slots on mainnet)
and affects only already-decided pre-fork aggregator stragglers. These
runners retire wholesale with the Alan topics.

Item 4 of #2968 (decision: document, don't slot-gate).
A garbage forks.boole epoch silently overflowed FirstSlotAtEpoch, and a
custom network scheduling Boole without setting next_domain_type
"activates" the fork with zero observable domain change (unmarshal
defaults the next domain to the current one). Add Network.Validate() -
hard error on the overflow and zero-slots-per-epoch cases,
operator-actionable warning on the same-domain case - called right
after the Network is assembled.

Item 6 of #2968.
The remap's magic upper bound (79) was disconnected from the real
v1.2.2 maximum (72). Derive it from TimeoutInstanceErrorCode - the last
pre-Boole-era spec error code - plus the documented +2 shift, so a spec
bump that adds codes can't silently widen the remap.

Item 7 of #2968.
@momosh-ssv
momosh-ssv requested review from a team as code owners July 30, 2026 12:32
@greptile-apps

greptile-apps Bot commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR adds Boole fork configuration validation during node startup and tightens Alan spectest compatibility behavior.

  • Rejects scheduled Boole forks whose slot conversion would divide by zero or overflow.
  • Warns operators when a scheduled fork leaves the domain type unchanged.
  • Documents the intentional share-add-time snapshot used for legacy Alan runners.
  • Derives the Alan error-code remapping boundary from the spec enum instead of a disconnected magic value.

Confidence Score: 5/5

The PR appears safe to merge, with no concrete blocking or independently actionable non-blocking issues identified.

The startup validation runs after the consensus client has initialized its beacon configuration, correctly handles the unscheduled-fork sentinel, and the remaining changes are scoped documentation and spectest compatibility refinements.

Important Files Changed

Filename Overview
cli/operator/node.go Validates the fully assembled network configuration before continuing node startup and logs operator-actionable warnings.
networkconfig/network.go Adds scheduled-Boole validation for zero slots per epoch, slot-conversion overflow, and unchanged domain types.
networkconfig/network_test.go Covers validation errors, warnings, valid scheduled configurations, and the unscheduled sentinel.
operator/validator/controller.go Documents why legacy runner selection is intentionally snapshotted when a share is added.
protocol/v2/qbft/spectest/error_code_map_alan.go Replaces the Alan compatibility remapping magic bound with one derived from the final legacy error-code enum.

Reviews (1): Last reviewed commit: "protocol/v2/qbft/spectest: derive the al..." | Re-trigger Greptile

@codecov

codecov Bot commented Jul 30, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 72.22222% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 65.1%. Comparing base (09a74d7) to head (c0411b7).

Files with missing lines Patch % Lines
cli/operator/node.go 0.0% 5 Missing ⚠️

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

1 participant