Skip to content

Replace get_dependent_root with get_shuffling_dependent_root - #5374

Merged
jtraglia merged 4 commits into
ethereum:masterfrom
mkalinin:fix-dependent-root
Jun 23, 2026
Merged

Replace get_dependent_root with get_shuffling_dependent_root#5374
jtraglia merged 4 commits into
ethereum:masterfrom
mkalinin:fix-dependent-root

Conversation

@mkalinin

Copy link
Copy Markdown
Contributor

This PR resolves #5351 by renaming get_dependent_root to get_shuffling_dependent_root to reflect the semantics of that function more precisely.

Alternative to #5352, the reason why that fix is less preferable is outlined in #5352 (comment).

Post-Fulu shuffling_dependent_root equals to proposer_dependent_root due to Deterministic proposer lookahead, but pre-Fulu proposer_dependent_root is one epoch later than shuffling_dependent_root because the balance change may affect proposer election under rare circumstances. Another argument in favor of not making Phase0 a special case is that Ethereum and Gnosis mainnet are already post-Fulu.

Incorporates changes to builder.md, validator.md and p2p-interface.md introduced by #5352.

Comment thread specs/gloas/fork-choice.md Outdated
Comment thread specs/gloas/p2p-interface.md
@jtraglia jtraglia changed the title Replace get_dependent_root with get_shuffling_dependent_root Replace get_dependent_root with get_shuffling_dependent_root Jun 18, 2026

@jtraglia jtraglia left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, thanks @mkalinin!

@jtraglia
jtraglia requested review from jihoonsong and nflaig June 18, 2026 17:21
Comment thread specs/gloas/validator.md Outdated

@nflaig nflaig left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, we have the exact same function and this aligns our code more with the spec

@jtraglia

Copy link
Copy Markdown
Member

Will wait for @michaelsproul to review before merging.

@jihoonsong jihoonsong left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good! I think it would be unnecessary to leave a note on get_shuffling_dependent_root is a bit flaky for proposer duty as it's fixed by EIP-7917 later.

@jihoonsong

Copy link
Copy Markdown
Member

In the SignedExecutionPayloadBid and SignedProposerPreferences, I've noticed that it uses slot value before setting it. I'll make a PR once this is merged.

@jtraglia

Copy link
Copy Markdown
Member

Thanks @jihoonsong. I'm going to merge this soon & let you follow up with the fix you mentioned tomorrow.

@jtraglia
jtraglia merged commit 76e97a0 into ethereum:master Jun 23, 2026
16 checks passed
tbenr added a commit to rolfyone/teku that referenced this pull request Jul 9, 2026
nflaig pushed a commit to ChainSafe/lodestar that referenced this pull request Jul 27, 2026
**Motivation**

After updating to consensus-specs v1.7.0-alpha.12, the entire
`gloas/fast_confirmation/*` suite was skipped because the
fast-confirmation runner could not process the Gloas (ePBS) vector
inputs. All 183 gloas cases failed at deserialization before reaching
any confirmation assertion. This restores the gloas portion of the
coverage tracked in #9690.

Spec references:

-
[ethereum/consensus-specs#5376](ethereum/consensus-specs#5376)
— enables `fast_confirmation` test generation for Gloas (and Heze),
producing the vectors handled here; also disables BLS in FCR test
generation, which is why envelope signature verification is gated on
`bls_setting=1`
-
[`specs/gloas/fast-confirmation.md`](https://github.com/ethereum/consensus-specs/blob/master/specs/gloas/fast-confirmation.md)
— the Gloas modifications to the FCR spec
([ethereum/consensus-specs#5278](ethereum/consensus-specs#5278),
[ethereum/consensus-specs#5249](ethereum/consensus-specs#5249))
-
[ethereum/consensus-specs#5249](ethereum/consensus-specs#5249)
— fork-choice redesign that added the nested `payload_status` to `head`
checks, asserted by this PR

**Description**

Port the Gloas execution-payload-envelope support from the fork-choice
runner into the fast-confirmation runner:

- Register `execution_payload_envelope_*.ssz_snappy` files with
`ssz.gloas.SignedExecutionPayloadEnvelope` and collect them into the
test case (previously every gloas case failed to load with `Cannot find
ssz type for inputName execution_payload_envelope_*`).
- Handle `execution_payload` steps: verify the envelope against the
block state, register the payload hash as VALID with the mock execution
engine, and call `forkChoice.onExecutionPayload()`.
- Skip envelope signature verification unless `bls_setting=1` — FCR
vectors are generated with BLS disabled (consensus-specs #5376),
mirroring how the runner already treats block signatures.
- Assert the `payload_status` nested inside `head` checks (new check
shape in the gloas FCR vectors), mapping spec numbering (EMPTY=0,
FULL=1, PENDING=2) to Lodestar's enum.
- Remove the `/^gloas\/fast_confirmation\/.*/` suite skip. The old skip
comment attributed the failures to unmodeled PTC payload-status
semantics; the actual cause was purely missing runner support — no FCR
implementation change was needed.
- Align the runner with `glamsterdam-devnet-7`: resolve attestation
shuffling from the attested block via `getShufflingDependentRoot` (spec
[ethereum/consensus-specs#5374](ethereum/consensus-specs#5374))
and seed the mock execution engine from `latestBlockHash` for gloas
anchor states.

The two `is_one_confirmed_fails_*` cases from #9690 remain skipped and
will be addressed in a follow-up PR (one needs the runner to replay the
generator's `on_fast_confirmation` schedule; the other hits an upstream
vector-generation artifact).

Results (minimal preset): `gloas/fast_confirmation` 181 passed / 2
skipped; full fast_confirmation suite across all forks 1243 passed / 6
skipped / 0 failed.

Refs #9690

**AI Assistance Disclosure**

- [x] I have read the [contributor
guidelines](https://github.com/ChainSafe/lodestar/blob/unstable/CONTRIBUTING.md#ai-assistance-notice)
and disclosed my usage of AI below.

Diagnosis and implementation done with AI assistance (Claude Code); all
changes reviewed and tests executed locally.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

get_dependent_root behaviour enshrines Fulu behaviour prior to Fulu

4 participants