Skip to content

fusaka devnet 2 branch #7269

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: vcus
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions beacon_chain/consensus_object_pools/block_pools_types.nim
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ type

erSlot*: Slot
## Earliest refilled slot is the earliest slot at which excess
## DataColumnSidecar downloading starts, if erSlot = GENESIS_SLOT
## DataColumnSidecar downloading finishes, if erSlot = GENESIS_SLOT
## we can deduce that validator custody is inactive.

validatorMonitor*: ref ValidatorMonitor
Expand Down Expand Up @@ -411,14 +411,13 @@ func earliestAvailableSlot*(dag: ChainDAGRef): Slot =
dag.backfill.slot != GENESIS_SLOT:
# When the BN is backfilling, backfill slot is the earliest
# persisted block.
dag.eaSlot = dag.backfill.slot
dag.backfill.slot
elif dag.erSlot != GENESIS_SLOT:
dag.eaSlot = dag.erSlot
# This indicates column filling due to validator custody
# is in progress
dag.erSlot
else:
# When the BN has backfilled, tail moves progressively.
dag.eaSlot = dag.tail.slot
dag.tail.slot

template epoch*(e: EpochRef): Epoch = e.key.epoch
Expand Down
9 changes: 3 additions & 6 deletions beacon_chain/sync/validator_custody.nim
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,9 @@ proc makeRefillList(vcus: ValidatorCustodyRef, diff: seq[ColumnIndex]) =
slot = vcus.getLocalHeadSlot()
dag = vcus.dag

if slot == dag.earliestAvailableSlot():
# Make earliest refilled slot go 18 days worth of slots behind
# in time to start refilling the excess custody columns
dag.erSlot =
dag.erSlot - (vcus.dag.cfg.MIN_EPOCHS_FOR_BLOB_SIDECARS_REQUESTS * 12) - 1
# Make earliest refilled slot go upto head because everything
# behind is currently undergoing excess column refilling.
dag.erSlot = slot

let dataColumnRefillEpoch = (slot.epoch -
vcus.dag.cfg.MIN_EPOCHS_FOR_BLOB_SIDECARS_REQUESTS - 1)
Expand Down Expand Up @@ -243,7 +241,6 @@ proc validatorCustodyColumnLoop(
# Reset the earliest refilled slot and make the
# earliest available slot tail.
vcus.dag.erSlot = GENESIS_SLOT
discard vcus.dag.earliestAvailableSlot()

proc start*(vcus: ValidatorCustodyRef) =
## Start Validator Custody detection loop
Expand Down
Loading