diff --git a/tests/test_execution_types.nim b/tests/test_execution_types.nim index 7362490..2e5c074 100644 --- a/tests/test_execution_types.nim +++ b/tests/test_execution_types.nim @@ -48,7 +48,7 @@ suite "Execution types tests": prevRandao: b32(2), suggestedFeeRecipient: address(3), withdrawals: Opt.some(@[wd]), - parentBeaconBlockRoot: Opt.some(b32(4)), + parentBeaconBlockRoot: Opt.some(h256(4)), ) blobs = BlobsBundleV1( @@ -110,7 +110,7 @@ suite "Execution types tests": test "attr version": var v2 = attr - v2.parentBeaconBlockRoot = Opt.none(Bytes32) + v2.parentBeaconBlockRoot = Opt.none(Hash32) var v1 = v2 v1.withdrawals = Opt.none(seq[WithdrawalV1]) check attr.version == Version.V3 diff --git a/web3/engine_api.nim b/web3/engine_api.nim index 09098a7..d5634da 100644 --- a/web3/engine_api.nim +++ b/web3/engine_api.nim @@ -26,8 +26,8 @@ createRpcSigsFromNim(RpcClient): proc engine_newPayloadV1(payload: ExecutionPayloadV1): PayloadStatusV1 proc engine_newPayloadV2(payload: ExecutionPayloadV2): PayloadStatusV1 - proc engine_newPayloadV3(payload: ExecutionPayloadV3, expectedBlobVersionedHashes: seq[VersionedHash], parentBeaconBlockRoot: Bytes32): PayloadStatusV1 - proc engine_newPayloadV4(payload: ExecutionPayloadV4, expectedBlobVersionedHashes: seq[VersionedHash], parentBeaconBlockRoot: Bytes32): PayloadStatusV1 + proc engine_newPayloadV3(payload: ExecutionPayloadV3, expectedBlobVersionedHashes: seq[VersionedHash], parentBeaconBlockRoot: Hash32): PayloadStatusV1 + proc engine_newPayloadV4(payload: ExecutionPayloadV4, expectedBlobVersionedHashes: seq[VersionedHash], parentBeaconBlockRoot: Hash32): PayloadStatusV1 proc engine_forkchoiceUpdatedV1(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Opt[PayloadAttributesV1]): ForkchoiceUpdatedResponse proc engine_forkchoiceUpdatedV2(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Opt[PayloadAttributesV2]): ForkchoiceUpdatedResponse proc engine_forkchoiceUpdatedV3(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Opt[PayloadAttributesV3]): ForkchoiceUpdatedResponse @@ -51,10 +51,10 @@ createRpcSigsFromNim(RpcClient): proc engine_newPayloadV2(payload: ExecutionPayloadV1OrV2): PayloadStatusV1 proc engine_newPayloadV3(payload: ExecutionPayload, expectedBlobVersionedHashes: Opt[seq[VersionedHash]], - parentBeaconBlockRoot: Opt[Bytes32]): PayloadStatusV1 + parentBeaconBlockRoot: Opt[Hash32]): PayloadStatusV1 proc engine_newPayloadV4(payload: ExecutionPayload, expectedBlobVersionedHashes: Opt[seq[VersionedHash]], - parentBeaconBlockRoot: Opt[Bytes32]): PayloadStatusV1 + parentBeaconBlockRoot: Opt[Hash32]): PayloadStatusV1 proc engine_forkchoiceUpdatedV2(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Opt[PayloadAttributes]): ForkchoiceUpdatedResponse proc engine_forkchoiceUpdatedV3(forkchoiceState: ForkchoiceStateV1, payloadAttributes: Opt[PayloadAttributes]): ForkchoiceUpdatedResponse diff --git a/web3/engine_api_types.nim b/web3/engine_api_types.nim index 329a79b..c2f3378 100644 --- a/web3/engine_api_types.nim +++ b/web3/engine_api_types.nim @@ -200,7 +200,7 @@ type prevRandao*: Bytes32 suggestedFeeRecipient*: Address withdrawals*: seq[WithdrawalV1] - parentBeaconBlockRoot*: Bytes32 + parentBeaconBlockRoot*: Hash32 # This is ugly, but see the comment on ExecutionPayloadV1OrV2. PayloadAttributesV1OrV2* = object diff --git a/web3/execution_types.nim b/web3/execution_types.nim index 83b8652..b40d6f4 100644 --- a/web3/execution_types.nim +++ b/web3/execution_types.nim @@ -43,7 +43,7 @@ type prevRandao*: Bytes32 suggestedFeeRecipient*: Address withdrawals*: Opt[seq[WithdrawalV1]] - parentBeaconBlockRoot*: Opt[Bytes32] + parentBeaconBlockRoot*: Opt[Hash32] SomeOptionalPayloadAttributes* = Opt[PayloadAttributesV1] |