From bfb7a4d6edbb56c9ae07cbe4117a2319adb5f3c7 Mon Sep 17 00:00:00 2001 From: Giulio rebuffo Date: Sat, 29 Apr 2023 21:31:54 +0200 Subject: [PATCH 1/6] return peer (#164) --- p2psentinel/sentinel.proto | 1 + 1 file changed, 1 insertion(+) diff --git a/p2psentinel/sentinel.proto b/p2psentinel/sentinel.proto index 5d3c84d..fe0abd5 100644 --- a/p2psentinel/sentinel.proto +++ b/p2psentinel/sentinel.proto @@ -52,6 +52,7 @@ message RequestData { message ResponseData { bytes data = 1; // prefix-stripped SSZ encoded data bool error = 2; // did the peer encounter an error + Peer peer = 3; } service Sentinel { From 6e13d1687a20c04833170df94f488e67974e1d3d Mon Sep 17 00:00:00 2001 From: Andrew Ashikhmin <34320705+yperbasis@users.noreply.github.com> Date: Fri, 5 May 2023 17:46:32 +0200 Subject: [PATCH 2/6] Header mix_digest -> prev_randao (#169) --- execution/execution.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/execution/execution.proto b/execution/execution.proto index 8a12955..4627796 100644 --- a/execution/execution.proto +++ b/execution/execution.proto @@ -36,7 +36,7 @@ message Header { types.H256 state_root = 3; types.H256 receipt_root = 4; types.H2048 logs_bloom = 5; - types.H256 mix_digest = 6; + types.H256 prev_randao = 6; uint64 block_number = 7; uint64 gas_limit = 8; uint64 gas_used = 9; From 6b2058cdcfbff176ccd5be195967b5b4664f7c40 Mon Sep 17 00:00:00 2001 From: Giulio rebuffo Date: Sun, 7 May 2023 00:27:58 +0200 Subject: [PATCH 3/6] Added blob sidecar type (#170) * lele * adapted * ops --- p2psentinel/sentinel.proto | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/p2psentinel/sentinel.proto b/p2psentinel/sentinel.proto index fe0abd5..561d512 100644 --- a/p2psentinel/sentinel.proto +++ b/p2psentinel/sentinel.proto @@ -9,17 +9,13 @@ import "types/types.proto"; message EmptyMessage {} enum GossipType { - // Lightclient gossip - LightClientFinalityUpdateGossipType = 0; - LightClientOptimisticUpdateGossipType = 1; - // Legacy gossip - BeaconBlockGossipType = 2; - // Global gossip topics. - AggregateAndProofGossipType = 3; - VoluntaryExitGossipType = 4; - ProposerSlashingGossipType = 5; - AttesterSlashingGossipType = 6; + BeaconBlockGossipType = 0; + AggregateAndProofGossipType = 1; + VoluntaryExitGossipType = 2; + ProposerSlashingGossipType = 3; + AttesterSlashingGossipType = 4; + BlobSidecarType = 5; } message Peer { @@ -30,6 +26,7 @@ message GossipData { bytes data = 1; // SSZ encoded data GossipType type = 2; optional Peer peer = 3; + optional uint32 blob_index = 4; // Blob identifier for EIP4844 } message Status { From f3dc88ab8729caafdb5b6fbd0034cbdcd39a8409 Mon Sep 17 00:00:00 2001 From: Roberto Bayardo Date: Thu, 25 May 2023 23:37:27 -0700 Subject: [PATCH 4/6] put blobs in payload response & add proofs to blobs bundle per 4844 spec updates (#171) --- remote/ethbackend.proto | 9 +++------ types/types.proto | 6 +++--- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/remote/ethbackend.proto b/remote/ethbackend.proto index dd944fc..75fa068 100644 --- a/remote/ethbackend.proto +++ b/remote/ethbackend.proto @@ -31,8 +31,8 @@ service ETHBACKEND { rpc EngineGetPayloadBodiesByRangeV1(EngineGetPayloadBodiesByRangeV1Request) returns (EngineGetPayloadBodiesV1Response); - // Fetch the blobs bundle using its ID. - rpc EngineGetBlobsBundleV1(EngineGetBlobsBundleRequest) returns (types.BlobsBundleV1); + // Fetch the payload along with its blobs bundle using its ID. + rpc EngineGetPayloadWithBlobs(EngineGetPayloadRequest) returns (EngineGetPayloadResponse); // End of Engine API requests // ------------------------------------------------------------------------ @@ -96,10 +96,6 @@ message EngineGetPayloadRequest { uint64 payload_id = 1; } -message EngineGetBlobsBundleRequest { - uint64 payload_id = 1; -} - enum EngineStatus { VALID = 0; INVALID = 1; @@ -141,6 +137,7 @@ message EngineForkChoiceUpdatedResponse { message EngineGetPayloadResponse { types.ExecutionPayload execution_payload = 1; types.H256 block_value = 2; + types.BlobsBundleV1 blobs_bundle = 3; } message ProtocolVersionRequest {} diff --git a/types/types.proto b/types/types.proto index 732b15c..5fc6a58 100644 --- a/types/types.proto +++ b/types/types.proto @@ -86,11 +86,11 @@ message Withdrawal { } message BlobsBundleV1 { - H256 block_hash = 1; // TODO(eip-4844): define a protobuf message for type KZGCommitment - repeated bytes kzgs = 2; + repeated bytes commitments = 1; // TODO(eip-4844): define a protobuf message for type Blob - repeated bytes blobs = 3; + repeated bytes blobs = 2; + repeated bytes proofs = 3; } // End of Engine API types From 4862127303bc46a9421d9014cf9144606fa8c730 Mon Sep 17 00:00:00 2001 From: Andrew Ashikhmin <34320705+yperbasis@users.noreply.github.com> Date: Fri, 2 Jun 2023 12:25:34 +0200 Subject: [PATCH 5/6] Merge EngineGetPayloadWithBlobs into EngineGetPayload (#173) --- remote/ethbackend.proto | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/remote/ethbackend.proto b/remote/ethbackend.proto index 75fa068..6ea1c49 100644 --- a/remote/ethbackend.proto +++ b/remote/ethbackend.proto @@ -24,16 +24,13 @@ service ETHBACKEND { // Update fork choice rpc EngineForkChoiceUpdated(EngineForkChoiceUpdatedRequest) returns (EngineForkChoiceUpdatedResponse); - // Fetch Execution Payload using its ID. + // Fetch the payload along with its blobs by ID. rpc EngineGetPayload(EngineGetPayloadRequest) returns (EngineGetPayloadResponse); rpc EngineGetPayloadBodiesByHashV1(EngineGetPayloadBodiesByHashV1Request) returns (EngineGetPayloadBodiesV1Response); rpc EngineGetPayloadBodiesByRangeV1(EngineGetPayloadBodiesByRangeV1Request) returns (EngineGetPayloadBodiesV1Response); - // Fetch the payload along with its blobs bundle using its ID. - rpc EngineGetPayloadWithBlobs(EngineGetPayloadRequest) returns (EngineGetPayloadResponse); - // End of Engine API requests // ------------------------------------------------------------------------ From cdc6e215fb3ed422ebe7afe3bafe70986ccf4d25 Mon Sep 17 00:00:00 2001 From: Andrew Ashikhmin <34320705+yperbasis@users.noreply.github.com> Date: Fri, 2 Jun 2023 12:45:41 +0200 Subject: [PATCH 6/6] EIP-4844: add data_gas_used (#172) --- execution/execution.proto | 3 ++- types/types.proto | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/execution/execution.proto b/execution/execution.proto index 4627796..6b9d8b6 100644 --- a/execution/execution.proto +++ b/execution/execution.proto @@ -49,7 +49,8 @@ message Header { types.H256 transaction_hash = 16; optional types.H256 base_fee_per_gas = 17; optional types.H256 withdrawal_hash = 18; - optional types.H256 excess_data_gas = 19; + optional uint64 data_gas_used = 19; + optional uint64 excess_data_gas = 20; } // Body is a block body for execution diff --git a/types/types.proto b/types/types.proto index 5fc6a58..f9a3ecd 100644 --- a/types/types.proto +++ b/types/types.proto @@ -75,7 +75,8 @@ message ExecutionPayload { H256 block_hash = 14; repeated bytes transactions = 15; repeated Withdrawal withdrawals = 16; - optional H256 excess_data_gas = 17; + optional uint64 data_gas_used = 17; + optional uint64 excess_data_gas = 18; } message Withdrawal {