`Opt[seq[Forky]]`

This commit is contained in:
Etan Kissling 2024-07-25 23:03:57 +02:00
parent eff1acd1dc
commit 9c9f2df0ca
No known key found for this signature in database
GPG Key ID: B21DA824C5A3D03D
4 changed files with 6 additions and 3 deletions

View File

@ -280,6 +280,9 @@ type
ForkyBlobSidecar* =
deneb.BlobSidecar
OptSeqForkyBlobSidecar* =
Opt[seq[deneb.BlobSidecar]]
ForkyBlobSidecars* =
deneb.BlobSidecars

View File

@ -1292,7 +1292,7 @@ proc proposeBlockAux(
Opt.some(signedBlock.create_blob_sidecars(
blobsBundle.proofs, blobsBundle.blobs))
else:
Opt.none(seq[BlobSidecar])
Opt.none(seq[deneb.BlobSidecar])
newBlockRef = (
await node.router.routeSignedBeaconBlock(signedBlock, blobsOpt,
checkValidator = false)

View File

@ -84,7 +84,7 @@ template getCurrentBeaconTime(router: MessageRouter): BeaconTime =
type RouteBlockResult = Result[Opt[BlockRef], string]
proc routeSignedBeaconBlock*(
router: ref MessageRouter, blck: ForkySignedBeaconBlock,
blobsOpt: Opt[seq[ForkyBlobSidecar]], checkValidator: bool):
blobsOpt: OptSeqForkyBlobSidecar, checkValidator: bool):
Future[RouteBlockResult] {.async: (raises: [CancelledError]).} =
## Validate and broadcast beacon block, then add it to the block database
## Returns the new Head when block is added successfully to dag, none when

View File

@ -138,7 +138,7 @@ proc unblindAndRouteBlockMEV*(
Opt.some(signedBlock.create_blob_sidecars(
blobs_bundle.proofs, blobs_bundle.blobs))
else:
Opt.none(seq[BlobSidecar])
Opt.none(seq[deneb.BlobSidecar])
debug "unblindAndRouteBlockMEV: proposing unblinded block",
blck = shortLog(signedBlock)