-
Notifications
You must be signed in to change notification settings - Fork 973
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
Align fork epoch with the start of EPOCHS_PER_SYNC_COMMITTEE_PERIOD
#2417
Conversation
@@ -68,7 +68,7 @@ Warning: this configuration is not definitive. | |||
| Name | Value | | |||
| - | - | | |||
| `MERGE_FORK_VERSION` | `Version('0x02000000')` | | |||
| `MERGE_FORK_EPOCH` | `Epoch(18446744073709551615)` **TBD** | | |||
| `MERGE_FORK_EPOCH` | `Epoch(9223372036854775808)` **TBD** | |
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.
the merge and sharding constants have to change as they are downstream of the altair fork so they need to have the alignment condition as well?
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.
That was only for simple alignment. Open to discussion! :)
i'm not opposed to this change but would say its more of a broader coordination issue across everyone who will be executing the fork -- the downside is that it constrains the timing of the fork (and raises the question how we want to handle future forks...) so that if e.g. we want to execute the fork at a given slot (bc the wall clock time is convenient for some reason) we may have to wait up to do ~48 hrs extra may be worth raising on the implementers call thursday to get input from more sources before merging this |
Is the alignment of the stubs (which are not supposed to be used) really necessary? I think we can just add a special case for the stub value in the invariant check. For non-stub values, I brought up the alignment issue during review in March here: #2201 (comment) A shorter period at the start seems fine to me if the test cannot avoid it. And yes, for mainnet we can align it nicely. And I would prefer an unit test that checks alignment of all mainnet fork version values, to keep the spec builder simple. |
Agreed! This alignment is half for aesthetic improvement and half for technical improvement. It would look bad if we somehow set |
Fair enough! I was thinking about putting invariant checks in the markdown file, but that was too messy. Moving to unit test should be good. |
Epoch(2**63)
and add pyspec invariant checkEPOCHS_PER_SYNC_COMMITTEE_PERIOD
Thanks for @ajsutton, @arnetheduck, @djrtwo, and @dankrad 's feedback on the call:
Other time period parameters:
Leaving this PR open for a few days in case we get new feedback. If no, I'll close this issue. :) edited: |
During the meeting, I think the I think1 day is fairly palatable however - should the proposal for #2417 be accepted, this alignment would help make the transition a lot easier. |
Oops, wrong link, should be #2428 |
closing for now, as discussed two calls ago this does not buy us too much on simplification |
Issue
EPOCHS_PER_SYNC_COMMITTEE_PERIOD
.If we do it, I'd like to add an invariant check to the pyspec builder. Therefore we have to adjust the temporary stub
ALTAIR_FORK_EPOCH
to the number that matches the assertion.Proposal
*_FORK_EPOCH
stub to2**63
.ALTAIR_FORK_EPOCH % EPOCHS_PER_SYNC_COMMITTEE_PERIOD == 0
checks to pyspec builder.