payloadId is now an 8-byte quantity, not per se a number

This commit is contained in:
Dustin Brody 2021-11-15 11:21:39 +00:00
parent 183cc8f407
commit 41fc21595c
No known key found for this signature in database
GPG Key ID: 3D7A11A0156519DC
2 changed files with 4 additions and 2 deletions

View File

@ -4,4 +4,4 @@ import ethtypes, engine_api_types
proc engine_executePayloadV1(payload: ExecutionPayloadV1): ExecutePayloadResponse proc engine_executePayloadV1(payload: ExecutionPayloadV1): ExecutePayloadResponse
proc engine_forkchoiceUpdatedV1(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Option[PayloadAttributesV1]): ForkchoiceUpdatedResponse proc engine_forkchoiceUpdatedV1(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Option[PayloadAttributesV1]): ForkchoiceUpdatedResponse
proc engine_getPayloadV1(payloadId: Quantity): ExecutionPayloadV1 proc engine_getPayloadV1(payloadId: PayloadID): ExecutionPayloadV1

View File

@ -19,6 +19,8 @@ type
invalid = "INVALID" invalid = "INVALID"
syncing = "SYNCING" syncing = "SYNCING"
PayloadID* = FixedBytes[8]
ExecutePayloadResponse* = object ExecutePayloadResponse* = object
status*: string status*: string
latestValidHash*: Option[BlockHash] latestValidHash*: Option[BlockHash]
@ -36,7 +38,7 @@ type
ForkchoiceUpdatedResponse* = object ForkchoiceUpdatedResponse* = object
status*: string status*: string
payloadId*: Option[Quantity] payloadId*: Option[PayloadID]
const const
# https://github.com/ethereum/execution-apis/blob/v1.0.0-alpha.4/src/engine/interop/specification.md#error-codes # https://github.com/ethereum/execution-apis/blob/v1.0.0-alpha.4/src/engine/interop/specification.md#error-codes