test(fc): block builder fixed-point justification loop#587
Merged
tcoratger merged 3 commits intoleanEthereum:mainfrom Apr 11, 2026
Merged
Conversation
Exercise the multi-pass behavior of `State.build_block` where processing attestation A advances `current_justified`, unlocking attestation B whose source was previously ineligible. Closes leanEthereum#564
tcoratger
reviewed
Apr 11, 2026
- Rewrite test_block_production.py docstring: trim from 60 to 28 lines, remove framework internals, use bullets and code-block diagrams - Replace all banner separator comments (# ── ... ──) with plain headings - Remove all backtick references from comments and docstrings - Move education into inline comments glued to each step: concrete threshold arithmetic, ASCII chain diagrams, structured labels (Invariant:, Why:, Timing:), pass-by-pass finalization trace - Fix incorrect "pronic: 1x2" claim to "immediate window (delta <= 5)" - Add attestation_slot=Slot(5) to AggregatedAttestationCheck entries - Add latest_justified_slot check on block_4 for tighter baseline - Add CLAUDE.md rule banning backtick references in comments/docstrings Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
tcoratger
approved these changes
Apr 11, 2026
2 tasks
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.
Summary
State.build_block, where processing attestation A advancescurrent_justifiedand unlocks attestation B whose source was previously ineligible.GossipAggregatedAttestationStepwith explicitsource_root_labeloverrides and tick-based payload migration to correctly model attestations with different source checkpoints reachinglatest_known_aggregated_payloadsbefore block production.attestation_checkscheckpoint on theTickStepto localize future failures between payload migration and fixed-point block building.Test plan
uv run fill --fork=devnet --clean -n auto -k test_block_builder_fixed_pointpassesuv run fill --fork=devnet --clean -n autopasses (124/124)ruff formatandruff checkcleanCloses #564