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

chore: Remove ChainSpec from PayloadConfig #11103

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

garwahl
Copy link
Contributor

@garwahl garwahl commented Sep 22, 2024

Closes #10951

Copy link
Contributor Author

@garwahl garwahl left a comment

Choose a reason for hiding this comment

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

Raised this draft to get some guidance as removing chainspec seems to break a few things, keen to understand either where we can pull it from or replace usages with something equiv. cc @mattsse

@@ -314,6 +314,7 @@ where
}

// calculate the requests and the requests root
// TODO (garwah): Figure out how to replace this check now that chain spec has been removed.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@mattsse It looks like chainspec is used heavily to determine what hardforks are active here, or threaded down eg.

if !chain_spec.is_cancun_active_at_timestamp(block_timestamp) {
return Ok(())
}

Do we have an alternative here for these checks or could we pull a chainspec from somewhere else?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Alternatively, we move the EthereumHardForks helper methods off ChainSpec onto something else

Comment on lines +316 to 317
// TODO (garwah): How do we instantiate EthEvmConfig as it requires chain spec
<reth_ethereum_payload_builder::EthereumPayloadBuilder as PayloadBuilder<Pool, Client>>::build_empty_payload(&reth_ethereum_payload_builder::EthereumPayloadBuilder::new(EthEvmConfig::new(chain_spec.clone())),client,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Similar issue here, it looks like pulling out chainspec will break instantiating a EthEvmConfig, any guidance here?

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.

remove chainspec from PayloadConfig
1 participant