File tree Expand file tree Collapse file tree 3 files changed +36
-0
lines changed
ethereum_test_forks/forks Expand file tree Collapse file tree 3 files changed +36
-0
lines changed Original file line number Diff line number Diff line change @@ -1284,6 +1284,13 @@ def engine_forkchoice_updated_version(
12841284class Osaka (Prague , solc_name = "cancun" ):
12851285 """Osaka fork."""
12861286
1287+ @classmethod
1288+ def engine_get_payload_version (
1289+ cls , block_number : int = 0 , timestamp : int = 0
1290+ ) -> Optional [int ]:
1291+ """From Osaka, get payload calls must use version 5."""
1292+ return 5
1293+
12871294 @classmethod
12881295 def evm_code_types (cls , block_number : int = 0 , timestamp : int = 0 ) -> List [EVMCodeType ]:
12891296 """EOF V1 is supported starting from Osaka."""
Original file line number Diff line number Diff line change 1515from .types import (
1616 ForkchoiceState ,
1717 ForkchoiceUpdateResponse ,
18+ GetBlobsResponse ,
1819 GetPayloadResponse ,
1920 JSONRPCError ,
2021 PayloadAttributes ,
@@ -344,3 +345,18 @@ def get_payload(
344345 ),
345346 context = self .response_validation_context ,
346347 )
348+
349+ def get_blobs (
350+ self ,
351+ params : List [Hash ],
352+ * ,
353+ version : int ,
354+ ) -> GetBlobsResponse :
355+ """`engine_getBlobsVX`: Retrieves blobs from an execution layers tx pool."""
356+ return GetBlobsResponse .model_validate (
357+ self .post_request (
358+ f"getBlobsV{ version } " ,
359+ * [to_json (param ) for param in params ],
360+ ),
361+ context = self .response_validation_context ,
362+ )
Original file line number Diff line number Diff line change @@ -136,9 +136,22 @@ def blob_versioned_hashes(self) -> List[Hash]:
136136 return [Hash (b"\1 " + commitment [1 :]) for commitment in self .commitments ]
137137
138138
139+ class BlobAndProof (CamelModel ):
140+ """Represents a blob and proof structure."""
141+
142+ blob : Bytes
143+ proofs : List [Bytes ]
144+
145+
139146class GetPayloadResponse (CamelModel ):
140147 """Represents the response of a get payload request."""
141148
142149 execution_payload : FixtureExecutionPayload
143150 blobs_bundle : BlobsBundle | None = None
144151 execution_requests : List [Bytes ] | None = None
152+
153+
154+ class GetBlobsResponse (CamelModel ):
155+ """Represents the response of a get blobs request."""
156+
157+ result : List [BlobAndProof ]
You can’t perform that action at this time.
0 commit comments