Serve real Gloas bids and envelopes from the auctioneer's existing submissions - #515
Open
0w3n-d wants to merge 1 commit into
Open
Conversation
…bmissions getExecutionPayloadBid now reads the winning submission out of the same bid-sorter/payloads map get_header already reads, converts it via the prior step's Gloas conversion functions, and signs a real SignedExecutionPayloadBid under helix's own configured builder identity. submitSignedBeaconBlock's GloasPayloadStore placeholder is replaced by a real auctioneer round trip (Event::TakeHeldGloasPayload) that looks up the same payload by block hash and converts it for envelope construction. GloasBuilderIdentity is now constructed once in main.rs and shared between the proposer API and the auctioneer. execution_payment is set equal to value (no payment-split product need yet, per #489).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue: #489 (step 6 of 6, per the reordering in #514)
What this PR does
getExecutionPayloadBidnow builds and signs a realSignedExecutionPayloadBid:it reads the winning submission out of
ctx.payloads/bid_sorter(the samemap
get_headeralready reads), converts it via the prior step'sto_lighthouse_gloas_payload/execution_requests_to_gloas, and signs underhelix's own configured
GloasBuilderIdentity-- no longer a permanentNoBidPreparedstub.submitSignedBeaconBlock'sGloasPayloadStore/NoHeldPayloadsplaceholder isreplaced by a real auctioneer round trip (
Event::TakeHeldGloasPayload) thatlooks up the same payload by block hash and converts it for envelope
construction.
GloasBuilderIdentityis now constructed once inmain.rs(fromconfig.gloas_builder_index+ the relay's signing keypair) and sharedbetween the proposer API and the auctioneer, instead of being built
separately inside
ProposerApi::new.execution_paymentis set equal tovalue(no payment-split product needyet -- see the resolved design note added to Gloas (ePBS) builder-API support #489).
What this PR deliberately does NOT do
submitBuilderPreferences'smax_execution_paymentagainstthe served bid -- still a known follow-up, unrelated to this step.
submitting via the existing
submit_blockpipeline exactly as before; thisPR only changes what happens to the winning submission when Gloas serves it.
Tests
Written before implementation, per this repo's workflow:
check_execution_payload_bid_livenesskeeps its 4 existing liveness tests(last one updated to expect
Ok(())now that a real bid follows).build_signed_bidtest: constructs aPayloadEntry, builds+signs a bid,checks every field maps from the entry/params/identity correctly, and
verifies the BLS signature against the configured identity.
construct_signed_envelope's 5 existing tests updated for the newOption<HeldGloasPayload>signature (same coverage, same assertions).Reviewer checklist
lint,unit-test) is greentouched, no obviously-wrong code the tests happen not to cover