fix: disable EIP3607 for eth_call and eth_estimateGas (#1961)

This commit is contained in:
Dan Cline
2023-03-24 12:14:03 -04:00
committed by GitHub
parent 934b78b496
commit 21e34da9c4
2 changed files with 10 additions and 2 deletions

View File

@ -25,7 +25,7 @@ reth-revm = { path = "../../revm" }
reth-tasks = { path = "../../tasks" }
# eth
revm = { version = "3.0.0", features = ["optional_block_gas_limit"] }
revm = { version = "3.0.0", features = ["optional_block_gas_limit", "optional_eip3607"] }
ethers-core = { git = "https://github.com/gakonst/ethers-rs", features = ["eip712"] }
revm-primitives = { version = "1.0", features = ["serde"] }

View File

@ -71,6 +71,10 @@ where
// impls and providers <https://github.com/foundry-rs/foundry/issues/4388>
cfg.disable_block_gas_limit = true;
// Disabled because eth_call is sometimes used with eoa senders
// See <htps://github.com/paradigmxyz/reth/issues/1959>
cfg.disable_eip3607 = true;
let request_gas = request.gas;
let mut env = build_call_evm_env(cfg, block, request)?;
@ -106,7 +110,7 @@ where
/// This will execute the [CallRequest] and find the best gas limit via binary search
fn estimate_gas_with<S>(
&self,
cfg: CfgEnv,
mut cfg: CfgEnv,
block: BlockEnv,
request: CallRequest,
state: S,
@ -114,6 +118,10 @@ where
where
S: StateProvider,
{
// Disabled because eth_estimateGas is sometimes used with eoa senders
// See <htps://github.com/paradigmxyz/reth/issues/1959>
cfg.disable_eip3607 = true;
// keep a copy of gas related request values
let request_gas = request.gas;
let request_gas_price = request.gas_price;