paradigmxyz / reth

Modular, contributor-friendly and blazing-fast implementation of the Ethereum protocol, in Rust
https://reth.rs/
Apache License 2.0
3.53k stars 913 forks source link

Integrate Request evm env filling in ethapi #9296

Open mattsse opened 4 days ago

mattsse commented 4 days ago

creating the TxEnv based on the TxRequest is done via:

https://github.com/paradigmxyz/reth/blob/edbbc9636eca770102f6ff33779130deb7b38360/crates/rpc/rpc-eth-types/src/revm_utils.rs#L119-L123

which currently requires OP feature

https://github.com/paradigmxyz/reth/blob/edbbc9636eca770102f6ff33779130deb7b38360/crates/rpc/rpc-eth-types/src/revm_utils.rs#L174-L175

this should be abstracted into a trait, ref:

https://github.com/paradigmxyz/reth/blob/edbbc9636eca770102f6ff33779130deb7b38360/crates/rpc/rpc-eth-api/src/helpers/call.rs#L268-L268

Ideally something new ConfigureEvmCallEnv or similar

nkysg commented 4 days ago

can I take this?

mattsse commented 4 days ago

assigned

mattsse commented 4 days ago

@nkysg for the initial pr I'm fine with keeping the feature and simply move the function as is into a trait that is implemented on EthApi

nkysg commented 4 days ago

@mattsse OK