Skip to content

Conversation

@mattsse
Copy link
Collaborator

@mattsse mattsse commented Jun 14, 2025

Similar to #16615 for OpAddOns, this relaxes the trait bounds on EthereumAddons to support custom engine validators and API builders. Also updates TestNode in exex test-utils to match the new generic structure.

Summary

This PR makes EthereumAddons more flexible by:

  • Adding generic type parameters for the ETH API builder, engine validator, and engine API builder
  • Relaxing trait bounds to use EthChainSpec + EthereumHardforks instead of hardcoded ChainSpec
  • Making EthereumEngineValidatorBuilder generic over ChainSpec
  • Adding methods with_engine_api() and with_engine_validator() to allow customization

Changes

  • Modified EthereumAddons to have generic parameters <N, EthB, EV, EB>
  • Updated TestNode in exex test-utils to match the new structure
  • Added necessary imports and trait bounds

This allows downstream users to customize validators while reusing EthereumAddons, avoiding code duplication.

fyi @rezbera

Similar to #16615 for OpAddOns, this relaxes the trait bounds on EthereumAddons
to support custom engine validators and API builders. Also updates TestNode
in exex test-utils to match the new generic structure.

This allows downstream users to customize validators while reusing EthereumAddons.
@github-project-automation github-project-automation bot moved this to Backlog in Reth Tracker Jun 14, 2025
@mattsse mattsse added the A-sdk Related to reth's use as a library label Jun 14, 2025
@mattsse mattsse marked this pull request as draft June 14, 2025 20:26
The Flashbots validation API integration was accidentally removed during
the refactoring. This commit restores it by:
- Adding back the ValidationApi initialization in launch_add_ons
- Adding required dependencies (reth-rpc-builder, reth-rpc-server-types)
- Importing necessary traits and types
@mattsse mattsse marked this pull request as ready for review June 14, 2025 20:30
@rezbera
Copy link
Contributor

rezbera commented Jun 16, 2025

awesome reduction in sdk LoC required berachain/bera-reth#7

@mattsse mattsse requested a review from fgimenez June 16, 2025 08:54
Copy link
Member

@fgimenez fgimenez left a comment

Choose a reason for hiding this comment

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

nice

@github-project-automation github-project-automation bot moved this from Backlog to In Progress in Reth Tracker Jun 16, 2025
@mattsse mattsse added this pull request to the merge queue Jun 16, 2025
Merged via the queue into main with commit ad86321 Jun 16, 2025
44 of 45 checks passed
@mattsse mattsse deleted the feat/relax-ethereum-addons branch June 16, 2025 09:54
@github-project-automation github-project-automation bot moved this from In Progress to Done in Reth Tracker Jun 16, 2025
PeaStew pushed a commit to NeuraProtocol/reth-new-consensus that referenced this pull request Jun 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-sdk Related to reth's use as a library

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants