-
Notifications
You must be signed in to change notification settings - Fork 99
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
Eth2Client: improvements, refactoring #882
Conversation
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.
Having these changes, we also need to add an extra verification to make sure that the chain is convergent. So block_hash_safe()
method would need to add a check that the block is safe only when block_number <= finalized_execution_header.block_number
.
But consequently, this also means that finalized_execution_blocks
variable no longer represents finalized blocks because the only finalized_execution_header
is actually final.
f690671
to
aefaec1
Compare
* utilize client modes for light client and execution blocks submission. * add checks for unfinalized tail block number. * add binsearch for a slot by block number. * delete unused functions. * remove irrelevant tests. * fix tests. --------- Co-authored-by: Karim <karim@aurora.dev> Co-authored-by: Kirill <kirill@aurora.dev>
* set `bitvec` version to 0.1.0. * set `hex` version to 0.4.3.
Refactor the eth2 light client to resolve an issue of missing finality for more than 5 epochs.
SubmitLightClientUpdate
andSubmitHeader
.SubmitLightClientUpdate
and it turns intoSubmitHeader
after submitting a light client update.LightClientUpdate
after any number of epochs/blocks, but those can be finalized only if the size of the gap between the current finalized block and the subsequent finalized block is higher thanhashes_gc_threshold
, otherwise, theGC
can't be applied correctly.eth2near
crates to v0.3.0.