-
Notifications
You must be signed in to change notification settings - Fork 957
Proposer duties backwards compat #8335
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
Proposer duties backwards compat #8335
Conversation
| epoch: Epoch, | ||
| head_block_root: Hash256, | ||
| ) -> Result<Hash256, Error> { | ||
| let decision_slot = epoch.saturating_sub(1u64).end_slot(E::slots_per_epoch()); |
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 think this is fine, but just want to note that the previous logic uses min_seed_lookahead, but no live network modifies this config
lighthouse/consensus/types/src/chain_spec.rs
Lines 894 to 900 in d67ae92
| // Pre-Fulu the proposer shuffling decision slot for epoch N is the slot at the end of | |
| // epoch N - 1 (note: +1 -1 for min_seed_lookahead=1 in all current configs). | |
| epoch | |
| .saturating_add(Epoch::new(1)) | |
| .saturating_sub(self.min_seed_lookahead) | |
| .start_slot(E::slots_per_epoch()) | |
| .saturating_sub(1_u64) |
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.
Oh yeah good point. Should be OK seeing as we plan to deprecate v1 proposer duties at Glamsterdam
jimmygchen
left a comment
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.
Looks good to me!
|
@mergify dequeue |
|
This pull request has been removed from the queue for the following reason: Pull request #8335 has been dequeued by a You should look at the reason for the failure and decide if the pull request needs to be fixed or if you want to requeue it. |
✅ The pull request has been removed from the queue
|
Squashed commit of the following: commit 258c13b Author: Michael Sproul <[email protected]> Date: Thu Oct 30 17:32:14 2025 +1100 Fix broken test commit f5368c8 Author: Michael Sproul <[email protected]> Date: Thu Oct 30 13:52:33 2025 +1100 Use legacy dependent root in v1 proposer duties endpoint commit e88ffd1 Author: Michael Sproul <[email protected]> Date: Thu Oct 30 13:06:07 2025 +1100 Start working on backwards compat
Squashed commit of the following: commit 258c13b Author: Michael Sproul <[email protected]> Date: Thu Oct 30 17:32:14 2025 +1100 Fix broken test commit f5368c8 Author: Michael Sproul <[email protected]> Date: Thu Oct 30 13:52:33 2025 +1100 Use legacy dependent root in v1 proposer duties endpoint commit e88ffd1 Author: Michael Sproul <[email protected]> Date: Thu Oct 30 13:06:07 2025 +1100 Start working on backwards compat
|
@Mergifyio requeue |
✅ The queue state of this pull request has been cleaned. It can be re-embarked automatically |
N/A Includes the following unmerged PRs: - #8344 - #8335 - #8339 This PR should be merged after all above PRs are merged. Co-Authored-By: Jimmy Chen <[email protected]> Co-Authored-By: Jimmy Chen <[email protected]>
Issue Addressed
The beacon API spec wasn't updated to use the Fulu definition of
dependent_rootfor the proposer duties endpoint. No other client updated their logic, so to retain backwards compatibility the decision has been made to continue using the block root at the end of epochN - 1, and introduce a new v2 endpoint down the track to use the correct dependent root.Eth R&D discussion: https://discord.com/channels/595666850260713488/598292067260825641/1433036715848765562
Proposed Changes
Change the behaviour of the v1 endpoint back to using the last slot of
N - 1rather than the last slot ofN - 2. This introduces the possibility of dependent root false positives (the root can change without changing the shuffling), but causes the least compatibility issues with other clients.