Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
73 changes: 39 additions & 34 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

45 changes: 22 additions & 23 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -226,17 +226,17 @@ foundry-compilers = { version = "0.18.0", default-features = false, features = [
] }

## revm
# No op-revm release supports revm 42 (op-revm 20.0.0 on crates.io pins revm
# ^38), so a shallow mirror of the ethereum-optimism monorepo commit matching
# the op-reth v2.6.0 release (workspace pins revm 42.0.1, the revm version at
# tag v115) is used instead. See the mirror's PROVENANCE.md.
op-revm = { git = "https://github.com/NomicFoundation/op-revm", tag = "op-reth-v2.6.0-da6d325", default-features = false, features = [
# No op-revm release supports revm 43 (op-revm 20.0.0 on crates.io pins revm
# ^38), so a shallow mirror of the ethereum-optimism monorepo commit that
# bumped op-revm to revm 43 (PR #23046, merged into `develop` on 2026-10-16;
# not in an op-reth release yet) is used instead. See the mirror's PROVENANCE.md.
op-revm = { git = "https://github.com/NomicFoundation/op-revm", rev = "5a0d3e5062c161818d61dbd588456dee8b1b42d1", default-features = false, features = [
"c-kzg",
"dev",
"serde",
"std",
] }
revm = { version = "42.0.1", default-features = false, features = [
revm = { version = "43.0.3", default-features = false, features = [
"arbitrary",
"blst",
"c-kzg",
Expand All @@ -248,39 +248,38 @@ revm = { version = "42.0.1", default-features = false, features = [
"serde",
"std",
] }
revm-bytecode = { version = "42.0.0", default-features = false, features = [
revm-bytecode = { version = "43.0.0", default-features = false, features = [
"serde",
"std",
] }
revm-context = { version = "42.0.0", default-features = false }
revm-context-interface = { version = "42.0.0", default-features = false }
revm-database-interface = { version = "=42.0.0", default-features = false }
revm-handler = { version = "42.0.1", default-features = false }
revm-inspector = { version = "42.0.1", default-features = false }
revm-interpreter = { version = "42.0.0", default-features = false }
revm-precompile = { version = "42.0.1", default-features = false, features = [
revm-context = { version = "43.0.3", default-features = false }
revm-context-interface = { version = "43.0.2", default-features = false }
revm-database-interface = { version = "=43.0.1", default-features = false }
revm-handler = { version = "43.0.3", default-features = false }
revm-inspector = { version = "43.0.3", default-features = false }
revm-interpreter = { version = "43.0.2", default-features = false }
revm-precompile = { version = "43.0.3", default-features = false, features = [
"blst",
"c-kzg",
"std",
] }
revm-primitives = { version = "42.0.0", default-features = false, features = [
revm-primitives = { version = "43.0.0", default-features = false, features = [
"hashbrown",
"rand",
"serde",
"std",
] }
revm-state = { version = "42.0.0", default-features = false }
revm-state = { version = "43.0.1", default-features = false }
c-kzg = { version = "2.1.8", default-features = false, features = [
"ethereum_kzg_settings",
] }

revm-inspectors = { version = "0.42.2", features = ["serde"] }
# No foundry-fork-db release supports revm 42 (0.27.0 on crates.io pins revm
# ^41; the next fork-db bump goes straight to revm 43), so a foundry-core git
# revision is used: the one Foundry v1.8.0 and v1.8.1 (the stable releases on
# revm 42) resolve foundry-fork-db to in their Cargo.lock; see
# https://github.com/foundry-rs/foundry/releases/tag/v1.8.1.
foundry-fork-db = { git = "https://github.com/foundry-rs/foundry-core", rev = "78e5b57f86986eabd969a5fdf238b8159f7086fd" }
revm-inspectors = { version = "0.44.1", features = ["serde"] }
# No foundry-fork-db release supports revm 43 (0.27.0 on crates.io pins revm
# ^41), so a foundry-core git revision is used: the one Foundry v1.8.5 (the
# latest stable release, on revm 43.0.3) resolves foundry-fork-db to in its
# Cargo.lock; see https://github.com/foundry-rs/foundry/releases/tag/v1.8.5.
foundry-fork-db = { git = "https://github.com/foundry-rs/foundry-core", rev = "39c03a49ade2f74a6e97e2af308283a42d78d302" }

## ethers
ethers-contract-abigen = { version = "2.0.14", default-features = false }
Expand Down
4 changes: 4 additions & 0 deletions crates/edr_provider/src/observability.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,11 @@ impl EvmObserver {
.map(CodeCoverageReporter::new);

let tracing_config = if config.verbose_raw_tracing {
// Executed bytecode and step deltas only serve Parity `vmTrace`,
// which EDR never produces.
TracingInspectorConfig::all()
.set_bytecode(false)
.set_step_deltas(false)
} else {
TracingInspectorConfig::default_parity()
.set_steps(true)
Expand Down
9 changes: 3 additions & 6 deletions crates/edr_provider/tests/integration/eip2780.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use edr_provider::{
};
use edr_runtime::transaction::CreationError;
use revm_primitives::{
eip2780::{TRANSFER_LOG_COST, TX_BASE_COST, TX_VALUE_COST},
eip2780::{TX_BASE_COST, TX_VALUE_COST},
eip8037::{CPSB_GLAMSTERDAM, NEW_ACCOUNT_BYTES},
eip8038::{COLD_ACCOUNT_ACCESS, CREATE_ACCESS},
};
Expand All @@ -36,9 +36,6 @@ const CONTRACT_ADDRESS: Address = address!("0x0000000000000000000000000000000000
/// Flat intrinsic gas of a transaction before Amsterdam.
const PRE_AMSTERDAM_INTRINSIC_GAS: u64 = 21_000;

/// EIP-2780: charge for a nonzero value sent to another account. revm still
/// splits the EIP's single charge into two constants.
const VALUE_CHARGE: u64 = TX_VALUE_COST + TRANSFER_LOG_COST;
/// EIP-8037: state gas of a new account.
const NEW_ACCOUNT_STATE_GAS: u64 = NEW_ACCOUNT_BYTES * CPSB_GLAMSTERDAM;

Expand Down Expand Up @@ -124,13 +121,13 @@ async fn value_transfer_pays_base_cost_recipient_access_and_value_charge_from_am
// intrinsic cost.
assert_eq!(
gas_used_by_sending(&amsterdam_provider, request.clone())?,
TX_BASE_COST + COLD_ACCOUNT_ACCESS + VALUE_CHARGE + NEW_ACCOUNT_STATE_GAS
TX_BASE_COST + COLD_ACCOUNT_ACCESS + TX_VALUE_COST + NEW_ACCOUNT_STATE_GAS
);
// To an existing account, the decomposed charges add up to the flat
// pre-Amsterdam cost.
assert_eq!(
gas_used_by_sending(&amsterdam_provider, request)?,
TX_BASE_COST + COLD_ACCOUNT_ACCESS + VALUE_CHARGE
TX_BASE_COST + COLD_ACCOUNT_ACCESS + TX_VALUE_COST
);

Ok(())
Expand Down
6 changes: 3 additions & 3 deletions crates/edr_provider/tests/integration/eip7981.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ const ACCESS_LIST_ADDRESS_COST: u64 = 2_400;
const ACCESS_LIST_STORAGE_KEY_COST: u64 = 1_900;

/// EIP-8038 per-item access list costs from Amsterdam onward (cold account
/// and cold storage access).
const EIP8038_ACCESS_LIST_ADDRESS_COST: u64 = 3_000;
const EIP8038_ACCESS_LIST_STORAGE_KEY_COST: u64 = 3_000;
/// and cold storage access less the warm access still charged at first use).
const EIP8038_ACCESS_LIST_ADDRESS_COST: u64 = 2_900;
const EIP8038_ACCESS_LIST_STORAGE_KEY_COST: u64 = 2_000;

/// Intrinsic cost of a nonzero calldata byte (EIP-2028).
const NONZERO_CALLDATA_BYTE_COST: u64 = 16;
Expand Down
2 changes: 1 addition & 1 deletion crates/edr_provider/tests/integration/eip8037.rs
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ fn rejects_transaction_exceeding_remaining_state_gas() -> anyhow::Result<()> {
#[test]
fn rejects_transaction_exceeding_remaining_execution_gas() -> anyhow::Result<()> {
const BLOCK_GAS_LIMIT: u64 = 400_000;
const SECOND_GAS_LIMIT: u64 = 150_000;
const SECOND_GAS_LIMIT: u64 = 250_000;

let mut fixture = new_fixture(BLOCK_GAS_LIMIT)?;

Expand Down
3 changes: 2 additions & 1 deletion crates/foundry/evm/core/src/backend/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2761,7 +2761,7 @@ mod tests {
use alloy_primitives::{Address, U256};
use alloy_provider::Provider;
use edr_test_utils::env::json_rpc_url_provider;
use foundry_fork_db::cache::{BlockchainDb, BlockchainDbMeta};
use foundry_fork_db::cache::{AccountFetchPolicy, BlockchainDb, BlockchainDbMeta};
use revm::{
context::{
result::{HaltReason, InvalidTransaction},
Expand Down Expand Up @@ -2833,6 +2833,7 @@ mod tests {
hosts: BTreeSet::default(),
fork_hash: None,
source_id: None,
account_fetch_policy: AccountFetchPolicy::Auto,
};

let db = BlockchainDb::new(
Expand Down
Loading
Loading