Skip to content

Commit cb9ffb4

Browse files
authored
fix: outstanding ssz issues after #1430 (#1432)
1 parent bcc7782 commit cb9ffb4

File tree

5 files changed

+14
-12
lines changed

5 files changed

+14
-12
lines changed

config/networks/mainnet/config.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,12 +135,14 @@ ATTESTATION_SUBNET_PREFIX_BITS: 6
135135
# Deneb
136136
# `2**7` (=128)
137137
MAX_REQUEST_BLOCKS_DENEB: 128
138-
# MAX_REQUEST_BLOCKS_DENEB * MAX_BLOBS_PER_BLOCK
139-
MAX_REQUEST_BLOB_SIDECARS: 768
140138
# `2**12` (= 4096 epochs, ~18 days)
141139
MIN_EPOCHS_FOR_BLOB_SIDECARS_REQUESTS: 4096
142140
# `6`
143141
BLOB_SIDECAR_SUBNET_COUNT: 6
142+
## 6 blobs
143+
MAX_BLOBS_PER_BLOCK: 6
144+
# MAX_REQUEST_BLOCKS_DENEB * MAX_BLOBS_PER_BLOCK (= 128 * 6) sidecars
145+
MAX_REQUEST_BLOB_SIDECARS: 768
144146

145147
# Whisk
146148
# `Epoch(2**8)`

config/networks/minimal/config.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,12 +135,14 @@ ATTESTATION_SUBNET_PREFIX_BITS: 6
135135
# Deneb
136136
# `2**7` (=128)
137137
MAX_REQUEST_BLOCKS_DENEB: 128
138-
# MAX_REQUEST_BLOCKS_DENEB * MAX_BLOBS_PER_BLOCK
139-
MAX_REQUEST_BLOB_SIDECARS: 768
140138
# `2**12` (= 4096 epochs, ~18 days)
141139
MIN_EPOCHS_FOR_BLOB_SIDECARS_REQUESTS: 4096
142140
# `6`
143141
BLOB_SIDECAR_SUBNET_COUNT: 6
142+
## 6 blobs
143+
MAX_BLOBS_PER_BLOCK: 6
144+
# MAX_REQUEST_BLOCKS_DENEB * MAX_BLOBS_PER_BLOCK (= 128 * 6) sidecars
145+
MAX_REQUEST_BLOB_SIDECARS: 768
144146

145147
# Whisk
146148
WHISK_EPOCHS_PER_SHUFFLING_PHASE: 4

config/presets/minimal/deneb.yaml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
# `uint64(4096)`
66
FIELD_ELEMENTS_PER_BLOB: 4096
77
# [customized]
8-
MAX_BLOB_COMMITMENTS_PER_BLOCK: 16
9-
# `uint64(6)`
10-
MAX_BLOBS_PER_BLOCK: 6
11-
# [customized] `floorlog2(get_generalized_index(BeaconBlockBody, 'blob_kzg_commitments')) + 1 + ceillog2(MAX_BLOB_COMMITMENTS_PER_BLOCK)` = 4 + 1 + 4 = 9
12-
KZG_COMMITMENT_INCLUSION_PROOF_DEPTH: 9
8+
MAX_BLOB_COMMITMENTS_PER_BLOCK: 32
9+
# [customized] floorlog2(get_generalized_index(BeaconBlockBody, 'blob_kzg_commitments')) + 1 + ceillog2(MAX_BLOB_COMMITMENTS_PER_BLOCK) (= 4 + 1 + 5 = 10)
10+
KZG_COMMITMENT_INCLUSION_PROOF_DEPTH: 10

lib/types/beacon_chain/beacon_block_body.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ defmodule Types.BeaconBlockBody do
3838
# max MAX_DEPOSITS
3939
deposits: list(Types.Deposit.t()),
4040
# max MAX_VOLUNTARY_EXITS
41-
voluntary_exits: list(Types.VoluntaryExit.t()),
41+
voluntary_exits: list(Types.SignedVoluntaryExit.t()),
4242
sync_aggregate: Types.SyncAggregate.t(),
4343
execution_payload: Types.ExecutionPayload.t(),
4444
# max MAX_BLS_TO_EXECUTION_CHANGES

native/ssz_nif/src/ssz_types/config.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,8 +131,8 @@ impl Config for Minimal {
131131
type SyncCommitteeSize = U32;
132132
type MaxWithdrawalsPerPayload = U4;
133133
type FieldElementsPerBlob = U4096;
134-
type MaxBlobCommitmentsPerBlock = U16;
135-
type KzgCommitmentInclusionProofDepth = U9;
134+
type MaxBlobCommitmentsPerBlock = U32;
135+
type KzgCommitmentInclusionProofDepth = U10;
136136
type MaxCommitteesPerSlot = U4;
137137
// Electra added fields
138138
type MaxDepositRequestsPerPayload = U4;

0 commit comments

Comments
 (0)