From 452fab58c729c364f3d1d46af62c8b529b69382e Mon Sep 17 00:00:00 2001 From: Akase Haruka Date: Mon, 27 May 2024 10:13:54 +0800 Subject: [PATCH] update revm to v36 (#1290) --- Cargo.lock | 28 ++++++++++++++-------------- Cargo.toml | 6 +++--- eth-types/src/l2_types.rs | 7 ++----- 3 files changed, 19 insertions(+), 22 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 4bb593ac82..20d6e092ab 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -100,9 +100,9 @@ checksum = "5c6cb57a04249c6480766f7f7cef5467412af1490f8d1e243141daddada3264f" [[package]] name = "alloy-primitives" -version = "0.7.0" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "99bbad0a6b588ef4aec1b5ddbbfdacd9ef04e00b979617765b03174318ee1f3a" +checksum = "db8aa973e647ec336810a9356af8aea787249c9d00b1525359f3db29a68d231b" dependencies = [ "alloy-rlp", "bytes", @@ -667,9 +667,9 @@ dependencies = [ [[package]] name = "c-kzg" -version = "1.0.0" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3130f3d8717cc02e668a896af24984d5d5d4e8bf12e278e982e0f1bd88a0f9af" +checksum = "cdf100c4cea8f207e883ff91ca886d621d8a166cb04971dfaa9bb8fd99ed95df" dependencies = [ "blst", "cc", @@ -3686,8 +3686,8 @@ dependencies = [ [[package]] name = "revm-precompile" -version = "6.0.0" -source = "git+https://github.com/scroll-tech/revm?rev=e1e8f7a#e1e8f7a2eb7ab7f0626713b7e33984881f8f7534" +version = "7.0.0" +source = "git+https://github.com/scroll-tech/revm?branch=scroll-evm-executor/v36#8543dd627348907773d8057807b6a310b276bb30" dependencies = [ "aurora-engine-modexp", "c-kzg", @@ -3695,15 +3695,15 @@ dependencies = [ "once_cell", "revm-primitives", "ripemd", - "secp256k1 0.28.2", + "secp256k1 0.29.0", "sha2", "substrate-bn", ] [[package]] name = "revm-primitives" -version = "3.1.1" -source = "git+https://github.com/scroll-tech/revm?rev=e1e8f7a#e1e8f7a2eb7ab7f0626713b7e33984881f8f7534" +version = "4.0.0" +source = "git+https://github.com/scroll-tech/revm?branch=scroll-evm-executor/v36#8543dd627348907773d8057807b6a310b276bb30" dependencies = [ "alloy-primitives", "auto_impl", @@ -4050,12 +4050,12 @@ dependencies = [ [[package]] name = "secp256k1" -version = "0.28.2" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d24b59d129cdadea20aea4fb2352fa053712e5d713eee47d700cd4b2bc002f10" +checksum = "0e0cc0f1cf93f4969faf3ea1c7d8a9faed25918d96affa959720823dfe86d4f3" dependencies = [ "rand", - "secp256k1-sys 0.9.2", + "secp256k1-sys 0.10.0", ] [[package]] @@ -4069,9 +4069,9 @@ dependencies = [ [[package]] name = "secp256k1-sys" -version = "0.9.2" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d1746aae42c19d583c3c1a8c646bfad910498e2051c551a7f2e3c0c9fbb7eb" +checksum = "1433bd67156263443f14d603720b082dd3121779323fce20cba2aa07b874bc1b" dependencies = [ "cc", ] diff --git a/Cargo.toml b/Cargo.toml index 84fc0eb393..3977473509 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -63,9 +63,9 @@ strum_macros = "0.25" subtle = "2.4" tokio = { version = "1.13", features = ["macros", "rt-multi-thread"] } url = "2.2" -revm-precompile = { git = "https://github.com/scroll-tech/revm", rev = "e1e8f7a", default-features = false, features = ["std"] } # v35 -revm-primitives = { git = "https://github.com/scroll-tech/revm", rev = "e1e8f7a", default-features = false, features = ["std"] } # v35 -c-kzg = "1.0.0" +revm-precompile = { git = "https://github.com/scroll-tech/revm", branch = "scroll-evm-executor/v36", default-features = false, features = ["std"] } # v36 +revm-primitives = { git = "https://github.com/scroll-tech/revm", branch = "scroll-evm-executor/v36", default-features = false, features = ["std"] } # v36 +c-kzg = "1.0.2" [patch.crates-io] ethers-core = { git = "https://github.com/scroll-tech/ethers-rs.git", branch = "v2.0.7" } diff --git a/eth-types/src/l2_types.rs b/eth-types/src/l2_types.rs index 39ba2e6a9d..f8075dfbfc 100644 --- a/eth-types/src/l2_types.rs +++ b/eth-types/src/l2_types.rs @@ -211,7 +211,7 @@ impl From<&TransactionTrace> for revm_primitives::TxEnv { gas_price: revm_primitives::U256::from_be_bytes(tx.gas_price.to_be_bytes()), transact_to: match tx.to { Some(to) => revm_primitives::TransactTo::Call(to.0.into()), - None => revm_primitives::TransactTo::Create(revm_primitives::CreateScheme::Create), + None => revm_primitives::TransactTo::Create, }, value: revm_primitives::U256::from_be_bytes(tx.value.to_be_bytes()), data: revm_primitives::Bytes::copy_from_slice(tx.data.as_ref()), @@ -239,10 +239,7 @@ impl From<&TransactionTrace> for revm_primitives::TxEnv { gas_priority_fee: tx .gas_tip_cap .map(|g| revm_primitives::U256::from_be_bytes(g.to_be_bytes())), - blob_hashes: vec![], - max_fee_per_blob_gas: None, - #[cfg(feature = "scroll")] - scroll: revm_primitives::ScrollFields::default(), + ..Default::default() } } }