Apply proposer boost if dependent roots match#5306
Conversation
jtraglia
left a comment
There was a problem hiding this comment.
Nice, I like this too. We'll need more client approvals before this can be merged though.
|
@mkalinin we should remove the following function & update the gossip condition to use the one introduced here. consensus-specs/specs/gloas/p2p-interface.md Lines 467 to 475 in 55519bb |
Okay yeah, that works too! |
Note that |
|
@mkalinin happy to merge this whenever you feel it's appropriate. I think we should probably get more reviews from clients. But I have a feeling this will be universally accepted as a good change. |
Good point. Note that |
|
Going to merge this. This was originally @potuz's idea here, @michaelsproul expressed support here, and @nflaig has expressed support via private chats. This is good enough for me. I don't expect this to be controversial. |
Follow up to #5300.
Switches from
proposer_indextodependent_rootcheck when applying proposer boost. There is an edge case whereproposer_indexis the same on the two competing chains with different dependent roots, in this case applying PB to the diverged chain can be exploited. This PR is a fix for that edge case.There are two ways how
dependent_rootcan be computed: 1) with the block tree, root and store time 2) with the post-state of a block. (1) since we do this computation in the FC context.Might worth makingget_dependent_rootan outer function.UPD: made
get_dependent_roota top-level function.