@@ -852,11 +852,10 @@ proc checkPayloadPresent(
852852 node.dag.db.getExecutionPayloadEnvelope (beacon_block_root, envelope) and
853853 envelope.message.beacon_block_root == beacon_block_root
854854 else :
855- return true
855+ true
856856
857857proc checkBlobDataAvailable (
858- node: BeaconNode , beacon_block_root: Eth2Digest
859- ): bool =
858+ node: BeaconNode , beacon_block_root: Eth2Digest ): bool =
860859 # # Check if the blob sidecars for this slot and envelope are available
861860
862861 let blckData = node.dag.getForkedBlock (beacon_block_root).valueOr:
@@ -873,22 +872,24 @@ proc checkBlobDataAvailable(
873872 if commitments.len == 0 :
874873 return true # No blobs required for this slot
875874
876- for i in 0 ..< commitments.len:
877- var blob: BlobSidecar
878- if not node.dag.db.getBlobSidecar (beacon_block_root, BlobIndex (i), blob):
875+ # check that our custody columns are available
876+ for columnIdx in node.dataColumnQuarantine.custodyColumns:
877+ var column: gloas.DataColumnSidecar
878+ if not node.dag.db.getDataColumnSidecar (
879+ beacon_block_root, columnIdx, column):
879880 return false
880- return true
881+ true
881882 else :
882- return true
883+ true
883884
884885proc createAndSendPayloadAttestation (node: BeaconNode ,
885- fork: Fork ,
886- genesis_validators_root: Eth2Digest ,
887- validator: AttachedValidator ,
888- validator_index: ValidatorIndex ,
889- slot: Slot ,
890- beacon_block_root: Eth2Digest )
891- {.async : (raises: [CancelledError ]).} =
886+ fork: Fork ,
887+ genesis_validators_root: Eth2Digest ,
888+ validator: AttachedValidator ,
889+ validator_index: ValidatorIndex ,
890+ slot: Slot ,
891+ beacon_block_root: Eth2Digest )
892+ {.async : (raises: [CancelledError ]).} =
892893 let
893894 payload_present = node.checkPayloadPresent (beacon_block_root)
894895 blob_data_available = node.checkBlobDataAvailable (beacon_block_root)
0 commit comments