-
Notifications
You must be signed in to change notification settings - Fork 279
implement validator custody with column refill mechanism #7127
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
base: column-syncer
Are you sure you want to change the base?
Conversation
for i in startIndex..<SLOTS_PER_EPOCH: | ||
let blck = vcus.dag.getForkedBlock(blocks[int(i)]).valueOr: continue | ||
withBlck(blck): | ||
when typeof(forkyBlck).kind < ConsensusFork.Fulu: continue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this ever happen? it's much cheaper to detect this before the block is ever fetched from the database, based on the slot number + fork schedule.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
detect this before the block is ever fetched from the database
the only way to make this cheaper is to see if the earliest data column in the database is against a Fulu block only then it makes sense to skip this check, imo, otherwise everytime we pull a finalized block from the DB, it's safe to check the fork, also say it can be a situation just a couple epochs after Fulu transition that on wanting block range i get EEEEEEFFFFFFF
, i want to refill only against the last Fulu blocks, and wanna continue for the first few Es, note that Es and Fs should ideally way more in number, this is just for an example
https://github.com/status-im/nimbus-eth2/actions/runs/14842398481/job/41668253800?pr=7127
|
…on for the validator custody loop
dataColumnRefillEpoch.start_slot, blocks.toOpenArray(0, SLOTS_PER_EPOCH - 1)) | ||
for i in startIndex..<SLOTS_PER_EPOCH: | ||
dataColumnRefillEpoch.start_slot, blocks.toOpenArray(0, slot.epoch().int - 1)) | ||
for i in startIndex..<slot.epoch().int: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
practically save but not that great to do this because (a) in theory 32/64-bit differences and (b) introduces potential Defect
due to int
conversion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see i
also has to be int(i)
a couple lines later, worth looking at the types here holistically.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's the same technique used in pruneSidecars
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not really great there either, but sure, it's consistent
No description provided.