Skip to content

Remove shuffling stable from fulu onwards - #11203

Open
gfukushima wants to merge 8 commits into
Consensys-Incorporated:masterfrom
gfukushima:remove-shuffling_stable-from-fulu-onwards
Open

Remove shuffling stable from fulu onwards#11203
gfukushima wants to merge 8 commits into
Consensys-Incorporated:masterfrom
gfukushima:remove-shuffling_stable-from-fulu-onwards

Conversation

@gfukushima

@gfukushima gfukushima commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

PR Description

Since the introduction of EIP 7917 (proposer lookahead) the shuffling in the proposers of the next epoch isn't possible at the last slot of the previous epoch. So from FULU onwards isForkChoiceStableAndFinalizationOk gets simplified to the single check isFinalizationOk

Fixed Issue(s)

Fixes #11150

Documentation

  • I thought about documentation and added the doc-change-required label to this PR if updates are required.

Changelog

  • I thought about adding a changelog entry, and added one if I deemed necessary.

Note

Medium Risk
Changes consensus fork-choice proposer-head behavior at epoch boundaries on Fulu; FCU override path is intentionally unchanged.

Overview
Aligns late-block proposer re-org logic with EIP-7917 (Fulu): getProposerHead no longer requires shuffling stability at epoch boundaries once the fork uses proposer lookahead.

The combined isForkChoiceStableAndFinalizationOk helper is replaced by isProposerStable plus isFinalizationOk. Pre-Fulu, isProposerStable still maps to is_shuffling_stable; ForkChoiceUtilFulu overrides it to always return true, so a late head at the last slot of an epoch can re-org to the parent when other checks pass. shouldOverrideForkChoiceUpdate still applies isShufflingStable and finalization separately (documented Teku-only conservatism for payload prep).

Adds ForkChoiceUtilReorgMilestoneTest (Bellatrix vs Fulu at an epoch boundary) and updates existing re-org tests and specrefs for Fulu get_proposer_head.

Reviewed by Cursor Bugbot for commit ee981ca. Bugbot is set up for automated code reviews on this repo. Configure here.

Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>
zilm13
zilm13 previously approved these changes Aug 31, 2026

@zilm13 zilm13 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
both comments are nit and optional

import tech.pegasys.teku.spec.logic.common.statetransition.exceptions.SlotProcessingException;

@TestSpecContext(milestone = {BELLATRIX, FULU})
class ForkChoiceUtilProposerHeadTest {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe ForkChoiceUtilReorgMilestoneTest?
The key purpose of this is to handle parameterized tests (compared to ForkChoiceUtilReorgTest)

final boolean isProposerBoostActive = isProposerBoostActive(store, headNode.blockRoot());
final boolean isShufflingStableAndForkChoiceOk =
isForkChoiceStableAndFinalizationOk(store, slot);
final boolean isProposerHeadReorgAllowed = isProposerHeadReorgAllowed(store, slot);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isProposerHeadReorgAllowed is a very general name which combines all the conditions together. What i suggest:
isFinalizationOk
isProposerStable: >fulu? true : isShuffilngStable

2 of those are different by meaning if I understand it correctly, there were not many reasons to combine them before, and even less now with fulu change.

Signed-off-by: Gabriel Fukushima <gabrielfukushima@gmail.com>

@zilm13 zilm13 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@lucassaldanha
lucassaldanha enabled auto-merge (squash) September 2, 2026 21:41
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.

Fulu: get_proposer_head still applies is_shuffling_stable (EIP-7917)

3 participants