fix more quarantine issues
This commit is contained in:
parent
52e8249e82
commit
6d837bcdaa
|
@ -74,7 +74,7 @@ func popDataColumns*(
|
||||||
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock):
|
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock):
|
||||||
seq[ref DataColumnSidecar] =
|
seq[ref DataColumnSidecar] =
|
||||||
var r: seq[ref DataColumnSidecar]
|
var r: seq[ref DataColumnSidecar]
|
||||||
for idx in 0..<len(blck.message.body.blob_kzg_commitments):
|
for idx in 0..<NUMBER_OF_COLUMNS:
|
||||||
var c: ref DataColumnSidecar
|
var c: ref DataColumnSidecar
|
||||||
if quarantine.data_columns.pop((digest, ColumnIndex idx), c):
|
if quarantine.data_columns.pop((digest, ColumnIndex idx), c):
|
||||||
r.add(c)
|
r.add(c)
|
||||||
|
@ -82,7 +82,7 @@ func popDataColumns*(
|
||||||
|
|
||||||
func hasDataColumns*(quarantine: DataColumnQuarantine,
|
func hasDataColumns*(quarantine: DataColumnQuarantine,
|
||||||
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock): bool =
|
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock): bool =
|
||||||
for idx in 0..<len(blck.message.body.blob_kzg_commitments):
|
for idx in 0..<NUMBER_OF_COLUMNS:
|
||||||
if (blck.root, ColumnIndex idx) notin quarantine.data_columns:
|
if (blck.root, ColumnIndex idx) notin quarantine.data_columns:
|
||||||
return false
|
return false
|
||||||
true
|
true
|
||||||
|
@ -90,7 +90,7 @@ func hasDataColumns*(quarantine: DataColumnQuarantine,
|
||||||
func dataColumnFetchRecord*(quarantine: DataColumnQuarantine,
|
func dataColumnFetchRecord*(quarantine: DataColumnQuarantine,
|
||||||
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock): DataColumnFetchRecord =
|
blck: deneb.SignedBeaconBlock | electra.SignedBeaconBlock): DataColumnFetchRecord =
|
||||||
var indices: seq[ColumnIndex]
|
var indices: seq[ColumnIndex]
|
||||||
for i in 0..<len(blck.message.body.blob_kzg_commitments):
|
for i in 0..<NUMBER_OF_COLUMNS:
|
||||||
let idx = ColumnIndex(i)
|
let idx = ColumnIndex(i)
|
||||||
if not quarantine.data_columns.hasKey(
|
if not quarantine.data_columns.hasKey(
|
||||||
(blck.root, idx)):
|
(blck.root, idx)):
|
||||||
|
|
|
@ -568,7 +568,7 @@ proc storeBlock(
|
||||||
withBlck(parentBlck.get()):
|
withBlck(parentBlck.get()):
|
||||||
when consensusFork >= ConsensusFork.Deneb:
|
when consensusFork >= ConsensusFork.Deneb:
|
||||||
var data_column_sidecars: DataColumnSidecars
|
var data_column_sidecars: DataColumnSidecars
|
||||||
for i in 0..<forkyBlck.message.body.blob_kzg_commitments.len:
|
for i in 0..<NUMBER_OF_COLUMNS:
|
||||||
let data_column = DataColumnSidecar.new()
|
let data_column = DataColumnSidecar.new()
|
||||||
if not dag.db.getDataColumnSidecar(parent_root, i.ColumnIndex, data_column[]):
|
if not dag.db.getDataColumnSidecar(parent_root, i.ColumnIndex, data_column[]):
|
||||||
columnsOk = false
|
columnsOk = false
|
||||||
|
|
Loading…
Reference in New Issue