Skip to content

Guard get_parent_payload_status at fork boundary#5125

Open
AbolareRoheemah wants to merge 2 commits into
ethereum:masterfrom
AbolareRoheemah:treat-pre-gloas-blocks-as-pending
Open

Guard get_parent_payload_status at fork boundary#5125
AbolareRoheemah wants to merge 2 commits into
ethereum:masterfrom
AbolareRoheemah:treat-pre-gloas-blocks-as-pending

Conversation

@AbolareRoheemah

Copy link
Copy Markdown
Contributor

get_parent_payload_status (and therefore is_parent_node_full) was unconditionally accessing the Gloas-only field parent.body.signed_execution_payload_bid even for pre-Gloas blocks.

This PR adds a guard that checks parent_state.fork.current_version and treats any pre-Gloas parent as PAYLOAD_STATUS_PENDING(matching the behavior Lighthouse already implements).

No changes were needed to on_block or is_parent_node_full.

All Gloas tests pass withmake test fork=gloas.

Fixes #5096

@brech1

brech1 commented Apr 24, 2026

Copy link
Copy Markdown
Member

Please review the proposed fix, it breaks post Gloas forks as it can be seen in the failed action:

@jtraglia jtraglia changed the title Gloas: guard get_parent_payload_status at fork boundary Guard get_parent_payload_status at fork boundary Apr 24, 2026
@AbolareRoheemah

Copy link
Copy Markdown
Contributor Author

Please review the proposed fix, it breaks post Gloas forks as it can be seen in the failed action:

Thanks for the review @brech1. I made a change now.

@brech1

brech1 commented Apr 29, 2026

Copy link
Copy Markdown
Member

Reading the discussion in ethereum/beacon-APIs#590 (comment) I'm uncertain on the consensus on what status to pin these blocks to.

cc @nflaig

@nflaig

nflaig commented Apr 29, 2026

Copy link
Copy Markdown
Member

Reading the discussion in ethereum/beacon-APIs#590 (comment) I'm uncertain on the consensus on what status to pin these blocks to.

cc @nflaig

not sure what the best solution is on the beacon-api but shouldn't the spec just use EMPTY?

parent = store.blocks[block.parent_root]
parent_state = store.block_states[block.parent_root]
# pre-Gloas parent has no bid field hence, treat as PENDING
if parent_state.fork.current_version < GLOAS_FORK_VERSION:

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.

Suggested change
if parent_state.fork.current_version < GLOAS_FORK_VERSION:
if compute_epoch_at_slot(block.slot) < GLOAS_FORK_EPOCH:

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.

The issue with this suggestion is that our testing framework doesn't work well with it 😢 currently, GLOAS_FORK_EPOCH is FAR_FUTURE_EPOCH so this condition will always be true. And it will always be true in the minimal preset, where we never schedule fork epochs.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Gloas: on_block is ill-defined at fork boundary

5 participants