-
Notifications
You must be signed in to change notification settings - Fork 939
Gloas process execution payload bid #8355
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Gloas process execution payload bid #8355
Conversation
cbe1afb to
ca2edb3
Compare
| !builder.slashed, | ||
| ExecutionPayloadBidInvalid::BuilderSlashed(builder_index).into() | ||
| ); | ||
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmmmm so the spec is written for clarity, not efficiency. Some of this work should be avoided if the amount is zero.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So true! def will keep that more top of mind when translating from spec to a performant code base. updated in commit 5ba3d54
| // Only perform payment related checks if amount > 0 | ||
| if amount > 0 { | ||
| // Verify builder is not slashed | ||
| block_verify!( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The spec verifies that the builder is not slashed even on self-builds (aka verifies the proposer is not slashed). This needs to be outside the amount or this could lead to a consensus fault under the right conditions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah, I see! makes sense since slashed proposer could technically be selected to produce block but hasn't exited yet. and we'd want to have this assert as a guard
also probably important for invalidating blocks with 0 value bids submitted by slashed off-protocol builders. since we may go the route of allowing builder api respond with a 0 value bid and an off_protocol_bid_value, then client can use that off_protocol_bid_value during bid selection
resolved in 7db4b92
ethDreamer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Changes per spec:
Added
process_execution_bidverify_execution_payload_header_signaturehas_builder_withdrawal_credentialis_builder_withdrawal_credentialModified
has_compounding_withdrawal_credentialHow this works
During block processing, we will no longer be verifying execution payloads but instead execution bids. These bids were submitted by in-protocol builders, and the winning bid is included in the block by the proposer.
During verification, we perform many checks to ensure the builder who submitted the bid has enough funds to cover their bid and also that the bid is for the current slot and that the bid's parent CL and EL block hashes correspond to those from previous block known in the
BeaconState.Additionally, we will add the bid's value to the
state.builder_pending_paymentslist.@ethDreamer
@eserilev