Skip to content

Commit 944ba01

Browse files
authored
eip7732: swap beacon_block_root and slot in places in DataColumnSidecar (#4656)
This PR swaps `beacon_block_root` and `slot` in places in `DataColumnSidecar`. Motivation: There are currently two versions of `DataColumnSidecar`. During deserialization from SSZ, it can be tricky to determine which container version to deserialize into. Having the same byte offset for the `slot` field in both versions allows clients to read the `slot` value from the bytes (and thus gain insight into the container version) before full deserialization.
1 parent d0548db commit 944ba01

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

specs/gloas/builder.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ def get_data_column_sidecars(
172172
column=column_cells,
173173
kzg_commitments=kzg_commitments,
174174
kzg_proofs=column_proofs,
175-
beacon_block_root=beacon_block_root,
176175
slot=slot,
176+
beacon_block_root=beacon_block_root,
177177
)
178178
)
179179
return sidecars

specs/gloas/p2p-interface.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,9 @@ class DataColumnSidecar(Container):
9898
# [Modified in Gloas:EIP7732]
9999
# Removed `kzg_commitments_inclusion_proof`
100100
# [New in Gloas:EIP7732]
101-
beacon_block_root: Root
102-
# [New in Gloas:EIP7732]
103101
slot: Slot
102+
# [New in Gloas:EIP7732]
103+
beacon_block_root: Root
104104
```
105105

106106
### Helpers

0 commit comments

Comments
 (0)