Skip to content

Conversation

@Evalir
Copy link
Member

@Evalir Evalir commented Dec 1, 2025

Closes ENG-1506.

Appropiately sets the SpecId for each chain, depending on which fork is active. This only discriminates between the "expected to activate" hard fork, and the current hard fork.

Closes ENG-1506.

Appropiately sets the `SpecId` for each chain, depending on which fork is active. This only discriminates between the "expected to activate" hard fork, and the current hard fork.
Copy link
Member Author

Evalir commented Dec 1, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@prestwich prestwich marked this pull request as draft December 1, 2025 18:32
@prestwich
Copy link
Member

converting to draft pending work discussed on slack

Copy link
Contributor

What work? Can we document that somewhere?

@Evalir Evalir requested a review from prestwich December 1, 2025 20:14
@prestwich
Copy link
Member

@dylanlott just conforming to the ticket w/ genesis


/// PecorinoCfg holds network-level configuration values.
/// The RU Pecorino [`ChainSpec`].
static PECORINO_SPEC: LazyLock<ChainSpec> =
Copy link
Member

Choose a reason for hiding this comment

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

when running the builder, we have a static config, so only 1 of pecorino or mainnet will ever be used. therefore we only need one lazylock here

Copy link
Member

Choose a reason for hiding this comment

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

we do need 1 for RU and 1 for host tho, no?

}

fn spec_id(&self) -> SpecId {
match self.chain_id {
Copy link
Member

@prestwich prestwich Dec 4, 2025

Choose a reason for hiding this comment

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

the chain id pair will not change during program operation, so the flow should initialize the lazylocked specs and then always read from those static specs, rather than matching on chain id each time the fn is invoked

Copy link
Member

Choose a reason for hiding this comment

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

basically, the first time we enter this, it should set the host and ru specs, and then it should only check the chainid for which of those to read

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.

4 participants