You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// The RPC payload attributes type the CL node emits via the engine API.
typePayloadAttributes:PayloadAttributes + Unpin;
with alloy-rs/alloy#227 we now have the case where the return type: ExecutionPayload is also no longer consistent which means those trait conversion functions are no longer entirely consistent:
The way it currently works is, the EngineTypes configure
The PayloadAttributes type: type we get from the CL
BuiltPayload: the type that payload builder service builds, which currently must be convertible into the versioned execution payload envelope
I think we now also the ExecutionPayloadV* types to be configurable, so that we can have clean types for all networks and don't need additional Options for OP for example, see alloy PR
TODO
we can solve this in a number of ways, but I think we want an additional associated type for the ExecutionPayload on the EngineTypes trait and then a requirement that the configured BuiltPayload can be converted into this type.
perhaps we want an associated type for each version or an enum, I assume 3 types might be easier to handle from engine impl POV:
Describe the feature
Currently we provide a way to abstract parts of the engine API (PayloadAttributes) because these are different eth vs OP
reth/crates/node-api/src/engine/mod.rs
Lines 19 to 24 in a4c0349
with alloy-rs/alloy#227 we now have the case where the return type:
ExecutionPayload
is also no longer consistent which means those trait conversion functions are no longer entirely consistent:reth/crates/node-api/src/engine/traits.rs
Lines 15 to 32 in a4c0349
The way it currently works is, the
EngineTypes
configureI think we now also the
ExecutionPayloadV*
types to be configurable, so that we can have clean types for all networks and don't need additional Options for OP for example, see alloy PRTODO
we can solve this in a number of ways, but I think we want an additional associated type for the
ExecutionPayload
on theEngineTypes
trait and then a requirement that the configuredBuiltPayload
can be converted into this type.perhaps we want an associated type for each version or an enum, I assume 3 types might be easier to handle from engine impl POV:
reth/crates/rpc/rpc-engine-api/src/engine_api.rs
Lines 253 to 256 in a4c0349
This would also require to introduce OP specific V3 type on alloy-rpc
@fgimenez would you be interested in this?
Additional context
No response
The text was updated successfully, but these errors were encountered: