Skip to content

Gloas fix genesis#9244

Open
eserilev wants to merge 8 commits intosigp:unstablefrom
eserilev:gloas-fix-genesis-part-deux
Open

Gloas fix genesis#9244
eserilev wants to merge 8 commits intosigp:unstablefrom
eserilev:gloas-fix-genesis-part-deux

Conversation

@eserilev
Copy link
Copy Markdown
Member

Issue Addressed

Some gloas genesis changes from glam devnet-0 didnt make it into our unstable branch somehow. This is needed to interop at genesis

jking-aus and others added 3 commits April 30, 2026 12:52
- Fix forkchoice update sending zero-hash head to EL at genesis by reading
  latest_block_hash from state when the genesis bid hashes are all zeros
- Simplify genesis block construction — the genesis block body is empty per
  spec, remove the incorrect bid-copying logic and body root override in
  initialize_beacon_state_from_eth1
@eserilev eserilev added ready-for-review The code is ready for review gloas labels Apr 30, 2026
@eserilev eserilev changed the title Gloas fix genesis part deux Gloas fix genesis Apr 30, 2026
@mergify
Copy link
Copy Markdown

mergify Bot commented Apr 30, 2026

Some required checks have failed. Could you please take a look @eserilev? 🙏

@mergify mergify Bot added waiting-on-author The reviewer has suggested changes and awaits thier implementation. and removed ready-for-review The code is ready for review labels Apr 30, 2026
Comment thread consensus/state_processing/src/genesis.rs Outdated
@michaelsproul
Copy link
Copy Markdown
Member

I reverted these changes to pass the spec tests. If this is needed for interop I think the genesis generator might still be wrong?

jking-aus added a commit that referenced this pull request Apr 30, 2026
The alpha-7 spec tests expect the Gloas genesis block body to contain
the execution payload bid from state. Restores the genesis_block()
function and body_root fixup that were removed in PR #9244.

The fork choice from_anchor fix (reading latest_block_hash when bid
hashes are zero) remains for Kurtosis/external genesis compatibility.
The alpha-7 spec tests expect the Gloas genesis block body to contain
the execution payload bid from state. Restores the genesis_block()
function and body_root fixup that were removed in PR sigp#9244.

The fork choice from_anchor fix (reading latest_block_hash when bid
hashes are zero) remains for Kurtosis/external genesis compatibility.
@jking-aus
Copy link
Copy Markdown
Member

jking-aus commented Apr 30, 2026

Pushed two additional commits:

  • 989eb4d — Restores genesis_block() bid population and body_root fixup (needed for alpha-7 ef-tests)
  • 78f22bemake_genesis_block falls back to BeaconBlock::empty(spec) when state body_root doesn't match (handles external genesis generators that use an empty block body for body_root)

@jimmygchen
Copy link
Copy Markdown
Member

I reverted these changes to pass the spec tests. If this is needed for interop I think the genesis generator might still be wrong?

Yeah I think we were correct and this PR makes it work with genesis generator. Not sure if we should merge this?

@michaelsproul
Copy link
Copy Markdown
Member

Feels like genesis generator should just fix its bullshit?

@michaelsproul
Copy link
Copy Markdown
Member

I've opened an issue to fix the genesis generator:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gloas waiting-on-author The reviewer has suggested changes and awaits thier implementation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants