Skip to content
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

In SpecVersion, make SpecConfig instance consistent with milestone #8830

Merged
merged 6 commits into from
Nov 14, 2024

Conversation

tbenr
Copy link
Contributor

@tbenr tbenr commented Nov 13, 2024

Currently, we always have the highest configured milestone SpecConfig instance associated to each SpecVersion.

This PR makes sure that SpecConfig version correspond to the SpecVersion for a given milestone.
For example, for mainnet network, we have SpecConfigPhase0 is returned when we do spec.atSlot(0).getConfig() even when Electra is configured.
Similarly for all milestones.

Fixes a counterintuitive behaviour that we frequently forget, causing wasted time, and enables some advanced usage of the SpecConfig (like abstracting away config params that are updated from a milestone to the next, like max blobs)

Documentation

  • I thought about documentation and added the doc-change-required label to this PR if updates are required.

Changelog

  • I thought about adding a changelog entry, and added one if I deemed necessary.

@tbenr tbenr force-pushed the SpecConfigAndParent branch from e6efa54 to 7326bb6 Compare November 13, 2024 16:46
@tbenr tbenr changed the title SpecConfigAndParent In SpecVersion, make SpecConfig instance consistent with milestone Nov 13, 2024
@tbenr tbenr force-pushed the SpecConfigAndParent branch 2 times, most recently from e6028d7 to 224e798 Compare November 13, 2024 16:58
@tbenr tbenr force-pushed the SpecConfigAndParent branch from 464bcfb to 6c730f6 Compare November 13, 2024 19:01
@tbenr tbenr requested a review from zilm13 November 14, 2024 11:19
@tbenr
Copy link
Contributor Author

tbenr commented Nov 14, 2024

SpecConfigAndParent or something like SpecConfigAndPreviousVersions ?

Copy link
Contributor

@zilm13 zilm13 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@tbenr tbenr merged commit c64dbea into Consensys:master Nov 14, 2024
16 of 17 checks passed
@tbenr tbenr deleted the SpecConfigAndParent branch November 14, 2024 15:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants