add more logging of KZG commitments, proofs, and blobs (#5735)
This commit is contained in:
parent
017f9f1103
commit
1559a09184
|
@ -195,6 +195,7 @@ proc storeBackfillBlock(
|
||||||
blockRoot = shortLog(signedBlock.root),
|
blockRoot = shortLog(signedBlock.root),
|
||||||
blobs = shortLog(blobs),
|
blobs = shortLog(blobs),
|
||||||
blck = shortLog(signedBlock.message),
|
blck = shortLog(signedBlock.message),
|
||||||
|
kzgCommits = mapIt(kzgCommits, shortLog(it)),
|
||||||
signature = shortLog(signedBlock.signature),
|
signature = shortLog(signedBlock.signature),
|
||||||
msg = r.error()
|
msg = r.error()
|
||||||
blobsOk = r.isOk()
|
blobsOk = r.isOk()
|
||||||
|
@ -539,6 +540,7 @@ proc storeBlock(
|
||||||
blockRoot = shortLog(signedBlock.root),
|
blockRoot = shortLog(signedBlock.root),
|
||||||
blobs = shortLog(blobs),
|
blobs = shortLog(blobs),
|
||||||
blck = shortLog(signedBlock.message),
|
blck = shortLog(signedBlock.message),
|
||||||
|
kzgCommits = mapIt(kzgCommits, shortLog(it)),
|
||||||
signature = shortLog(signedBlock.signature),
|
signature = shortLog(signedBlock.signature),
|
||||||
msg = r.error()
|
msg = r.error()
|
||||||
return err((VerifierError.Invalid, ProcessingStatus.completed))
|
return err((VerifierError.Invalid, ProcessingStatus.completed))
|
||||||
|
|
|
@ -508,6 +508,12 @@ type
|
||||||
func initHashedBeaconState*(s: BeaconState): HashedBeaconState =
|
func initHashedBeaconState*(s: BeaconState): HashedBeaconState =
|
||||||
HashedBeaconState(data: s)
|
HashedBeaconState(data: s)
|
||||||
|
|
||||||
|
func shortLog*(v: KzgCommitment | KzgProof): auto =
|
||||||
|
to0xHex(v)
|
||||||
|
|
||||||
|
func shortLog*(v: Blob): auto =
|
||||||
|
to0xHex(v.toOpenArray(0, 31))
|
||||||
|
|
||||||
func shortLog*(v: SomeBeaconBlock): auto =
|
func shortLog*(v: SomeBeaconBlock): auto =
|
||||||
(
|
(
|
||||||
slot: shortLog(v.slot),
|
slot: shortLog(v.slot),
|
||||||
|
@ -534,8 +540,11 @@ func shortLog*(v: SomeBeaconBlock): auto =
|
||||||
func shortLog*(v: BlobSidecar): auto =
|
func shortLog*(v: BlobSidecar): auto =
|
||||||
(
|
(
|
||||||
index: v.index,
|
index: v.index,
|
||||||
|
blob: shortLog(v.blob),
|
||||||
bloblen: v.blob.len(),
|
bloblen: v.blob.len(),
|
||||||
block_header: shortLog(v.signed_block_header.message),
|
block_header: shortLog(v.signed_block_header.message),
|
||||||
|
kzg_commitment: shortLog(v.kzg_commitment),
|
||||||
|
kzg_proof: shortLog(v.kzg_proof),
|
||||||
)
|
)
|
||||||
|
|
||||||
func shortLog*(v: seq[BlobSidecar]): auto =
|
func shortLog*(v: seq[BlobSidecar]): auto =
|
||||||
|
|
Loading…
Reference in New Issue