Skip to content

Wire getExecutionPayloadBid to the auctioneer, checking parent_hash/parent_root - #507

Open
0w3n-d wants to merge 1 commit into
od/gloas-step2-envelope-broadcastfrom
od/gloas-step3-execution-payload-bid
Open

Wire getExecutionPayloadBid to the auctioneer, checking parent_hash/parent_root#507
0w3n-d wants to merge 1 commit into
od/gloas-step2-envelope-broadcastfrom
od/gloas-step3-execution-payload-bid

Conversation

@0w3n-d

@0w3n-d 0w3n-d commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Issue: #489 (step 3 of 6)

Stacked on #503 — base branch is od/gloas-step2-envelope-broadcast. Retarget to develop once #501/#503 merge.

What this PR does

getExecutionPayloadBid needs to check whether the requested parent_root is currently live -- that state (SlotData.payload_attributes_map) only exists inside the single-threaded auctioneer actor, reached via AuctioneerHandle. This mirrors get_header's existing architecture rather than the direct-trait-injection pattern step 2 used (that pattern doesn't fit here: step 2's envelope construction only needed one already-submitted payload, not live per-slot head-tracking state).

  • New Event::GetExecutionPayloadBid + AuctioneerHandle::get_execution_payload_bid, parallel to GetHeader.
  • Context::get_execution_payload_bid: checks the request's parent_hash against payload_attributes_map, then checks that entry's parent_beacon_block_root matches the request's parent_root (the two must be compatible, i.e. from the same beacon state, per spec).
  • The handler now calls through to the auctioneer instead of unconditionally returning NO_CONTENT.
  • ExecutionPayloadBid/SignedExecutionPayloadBid type aliases added to helix_types.

What this PR deliberately does not do

Never actually serves a bid -- every request currently reports "no bid available" (NoBidPrepared, a valid spec response), whether or not the parent checks pass. Serving a real bid needs a Gloas-shaped payload store, which needs step 5's builder→relay submission wire format. max_execution_payment enforcement is likewise not implemented: there's no value/execution_payment split to enforce it against yet, and step 4 hasn't landed the preference store. Both are next steps once step 5 lands.

Tests

  • get_execution_payload_bid (pure function, independent of the heavy Context type): unknown parent hash, parent root mismatch, missing parent_beacon_block_root, and matching parent (still no bid, by design) — all four report NoBidPrepared, proving the guards actually run rather than short-circuiting.

Reviewer checklist

  • CI (lint, unit-test) is green
  • Matches the linked issue/step
  • No unexplained scope creep or unrelated files touched

@0w3n-d
0w3n-d force-pushed the od/gloas-step3-execution-payload-bid branch from 5e7384a to 1655d23 Compare August 25, 2026 12:56
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.

1 participant