-
Notifications
You must be signed in to change notification settings - Fork 866
Implement basic validator custody #7262
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: unstable
Are you sure you want to change the base?
Conversation
This pull request has merge conflicts. Could you please resolve them @dapplion? 🙏 |
beacon_node/network/src/service.rs
Outdated
// We need backfill sync to fetch batches with `CGC_f = cgc_at_finalized_slot`. Then | ||
// `custody_group_count(oldest_block_slot) should now return `CGC_f`. So we have to | ||
// delete the CGC updates with `update.slot < finalized_slot` | ||
todo!(); |
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.
To prevent concurrent updates of oldest_block_slot
, we can get import_historical_block_batch
to handle the mutation for us.
We can add an argument to that function, something like restart: bool
, and set the oldest_block_{slot,root}
to the last block in the batch passed in (allowing the oldest_block_slot
to go up).
TODO: what if state reconstruction is running as well?
- Need to consider how state reconstruction depends on and modifies
oldest_block_slot
. Should maybe makeas_archive_anchor()
preserve the oldest block slot
Alternatively, make sure we only restart backfill if oldest_block_slot > 0
(might affect some testnets with FULU_FORK_EPOCH=0
, but not mainnet). Actually we need to consider max(oldest_block_slot, fulu_fork_slot, clock_slot - da_window)
Issue Addressed
Also does a consistency check on the DB to make sure the stored columns are compatible
Not tested yet
Proposed Changes
TODO