Skip to content

Commit d51e841

Browse files
committed
resolve docstring reviews
1 parent 3bbb42a commit d51e841

2 files changed

Lines changed: 20 additions & 57 deletions

File tree

packages/testing/src/execution_testing/ssz/containers.py

Lines changed: 16 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,7 @@ class Withdrawal(Container):
5454

5555

5656
class ExecutionPayloadParis(Container):
57-
"""
58-
The Paris execution payload.
59-
"""
57+
"""The Paris execution payload."""
6058

6159
parent_hash: Hash32
6260
fee_recipient: Address
@@ -75,9 +73,7 @@ class ExecutionPayloadParis(Container):
7573

7674

7775
class ExecutionPayloadShanghai(Container):
78-
"""
79-
The Shanghai execution payload.
80-
"""
76+
"""The Shanghai execution payload."""
8177

8278
parent_hash: Hash32
8379
fee_recipient: Address
@@ -97,9 +93,7 @@ class ExecutionPayloadShanghai(Container):
9793

9894

9995
class ExecutionPayloadCancun(Container):
100-
"""
101-
The Cancun execution payload.
102-
"""
96+
"""The Cancun execution payload."""
10397

10498
parent_hash: Hash32
10599
fee_recipient: Address
@@ -121,9 +115,7 @@ class ExecutionPayloadCancun(Container):
121115

122116

123117
class ExecutionPayloadPrague(Container):
124-
"""
125-
The Prague execution payload.
126-
"""
118+
"""The Prague execution payload."""
127119

128120
parent_hash: Hash32
129121
fee_recipient: Address
@@ -145,9 +137,7 @@ class ExecutionPayloadPrague(Container):
145137

146138

147139
class ExecutionPayloadOsaka(Container):
148-
"""
149-
The Osaka execution payload.
150-
"""
140+
"""The Osaka execution payload."""
151141

152142
parent_hash: Hash32
153143
fee_recipient: Address
@@ -169,9 +159,7 @@ class ExecutionPayloadOsaka(Container):
169159

170160

171161
class ExecutionPayloadAmsterdam(Container):
172-
"""
173-
The Amsterdam execution payload.
174-
"""
162+
"""The Amsterdam execution payload."""
175163

176164
parent_hash: Hash32
177165
fee_recipient: Address
@@ -205,34 +193,26 @@ class ExecutionPayloadAmsterdam(Container):
205193

206194

207195
class ExecutionPayloadEnvelopeParis(Container):
208-
"""
209-
The Paris `newPayload` envelope.
210-
"""
196+
"""The Paris `newPayload` envelope."""
211197

212198
payload: ExecutionPayloadParis
213199

214200

215201
class ExecutionPayloadEnvelopeShanghai(Container):
216-
"""
217-
The Shanghai `newPayload` envelope.
218-
"""
202+
"""The Shanghai `newPayload` envelope."""
219203

220204
payload: ExecutionPayloadShanghai
221205

222206

223207
class ExecutionPayloadEnvelopeCancun(Container):
224-
"""
225-
The Cancun `newPayload` envelope.
226-
"""
208+
"""The Cancun `newPayload` envelope."""
227209

228210
payload: ExecutionPayloadCancun
229211
parent_beacon_block_root: Root
230212

231213

232214
class ExecutionPayloadEnvelopePrague(Container):
233-
"""
234-
The Prague `newPayload` envelope.
235-
"""
215+
"""The Prague `newPayload` envelope."""
236216

237217
payload: ExecutionPayloadPrague
238218
parent_beacon_block_root: Root
@@ -243,9 +223,7 @@ class ExecutionPayloadEnvelopePrague(Container):
243223

244224

245225
class ExecutionPayloadEnvelopeOsaka(Container):
246-
"""
247-
The Osaka `newPayload` envelope.
248-
"""
226+
"""The Osaka `newPayload` envelope."""
249227

250228
payload: ExecutionPayloadOsaka
251229
parent_beacon_block_root: Root
@@ -256,9 +234,7 @@ class ExecutionPayloadEnvelopeOsaka(Container):
256234

257235

258236
class ExecutionPayloadEnvelopeAmsterdam(Container):
259-
"""
260-
The Amsterdam `newPayload` envelope.
261-
"""
237+
"""The Amsterdam `newPayload` envelope."""
262238

263239
payload: ExecutionPayloadAmsterdam
264240
parent_beacon_block_root: Root
@@ -356,13 +332,7 @@ class ForkchoiceState(Container):
356332

357333

358334
class PayloadStatus(Container):
359-
"""
360-
A newPayload/forkchoice status.
361-
362-
``status`` is a uint8 enum (0=VALID, 1=INVALID, 2=SYNCING, 3=ACCEPTED).
363-
``latest_valid_hash`` is ``Optional[Hash32]`` and ``validation_error`` is
364-
``Optional[String]``.
365-
"""
335+
"""A newPayload/forkchoice status."""
366336

367337
status: uint8
368338
latest_valid_hash: List[Hash32, 1]
@@ -522,9 +492,7 @@ class BuiltPayloadCancun(Container):
522492

523493

524494
class BuiltPayloadPrague(Container):
525-
"""
526-
The Prague getPayload response.
527-
"""
495+
"""The Prague getPayload response."""
528496

529497
payload: ExecutionPayloadPrague
530498
block_value: uint256
@@ -587,10 +555,7 @@ class BlobAndProofV2(Container):
587555

588556

589557
class BlobCellsAndProofs(Container):
590-
"""
591-
Cell-range blob contents (/blobs/v4, Amsterdam).
592-
Each cell and proof is ``Optional``.
593-
"""
558+
"""Cell-range blob contents for /blobs/v4 (cells/proofs optional)."""
594559

595560
blob_cells: List[List[ByteVector[BYTES_PER_CELL], 1], CELLS_PER_EXT_BLOB]
596561
proofs: List[List[Bytes48, 1], CELLS_PER_EXT_BLOB]
@@ -603,9 +568,7 @@ class BodiesByHashRequest(Container):
603568

604569

605570
class BodyEntry(Container):
606-
"""
607-
One bodies-response entry.
608-
"""
571+
"""One bodies-response entry."""
609572

610573
available: boolean
611574
body: ExecutionPayloadBodyAmsterdam

packages/testing/src/execution_testing/ssz/ssz_types.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77

88
class Hash32(ByteVector[32]):
9-
"""A 32-byte hash (`Hash32`, `Root` and `Bytes32` share this layout)."""
9+
"""A 32-byte hash."""
1010

1111

1212
class Bytes32(ByteVector[32]):
@@ -30,12 +30,12 @@ class VersionedHash(ByteVector[32]):
3030

3131

3232
class Bytes8(ByteVector[8]):
33-
"""An 8-byte value (e.g. `payload_id`)."""
33+
"""An 8-byte value."""
3434

3535

3636
class Bytes4(ByteVector[4]):
37-
"""A 4-byte value (e.g. a client commit hash)."""
37+
"""A 4-byte value."""
3838

3939

4040
class Bytes48(ByteVector[48]):
41-
"""A 48-byte value (KZG commitments and proofs)."""
41+
"""A 48-byte value."""

0 commit comments

Comments
 (0)