From 05a4c238e26c05f2f25f44edd2a0b8a149a1c0b9 Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Fri, 9 Feb 2024 13:40:55 +0330 Subject: [PATCH 1/6] Add tevmmainnet-base and tevmtestnet-base to the list of supported chainss --- crates/node-core/src/args/utils.rs | 12 ++- crates/node-core/src/dirs.rs | 12 +++ crates/node-core/src/init.rs | 35 +++++++- .../primitives/res/genesis/tevmmainnet.json | 2 +- .../res/genesis/tevmmainnet_base.json | 13 +++ .../primitives/res/genesis/tevmtestnet.json | 2 +- .../res/genesis/tevmtestnet_base.json | 13 +++ crates/primitives/src/chain/mod.rs | 2 +- crates/primitives/src/chain/spec.rs | 82 ++++++++++++++++++- crates/primitives/src/constants/mod.rs | 11 +++ crates/primitives/src/lib.rs | 4 +- crates/primitives/src/proofs.rs | 22 ++++- .../src/providers/database/provider.rs | 1 - 13 files changed, 200 insertions(+), 11 deletions(-) create mode 100644 crates/primitives/res/genesis/tevmmainnet_base.json create mode 100644 crates/primitives/res/genesis/tevmtestnet_base.json diff --git a/crates/node-core/src/args/utils.rs b/crates/node-core/src/args/utils.rs index 0a16d0fd3e32..588b23d09563 100644 --- a/crates/node-core/src/args/utils.rs +++ b/crates/node-core/src/args/utils.rs @@ -16,7 +16,7 @@ use reth_primitives::{BASE_MAINNET, BASE_SEPOLIA}; use reth_primitives::{DEV, GOERLI, HOLESKY, MAINNET, SEPOLIA}; #[cfg(feature = "telos")] -use reth_primitives::{TEVMMAINNET, TEVMTESTNET}; +use reth_primitives::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; #[cfg(not(feature = "telos"))] #[cfg(feature = "optimism")] @@ -28,7 +28,7 @@ pub const SUPPORTED_CHAINS: &[&str] = &["base", "base-sepolia"]; pub const SUPPORTED_CHAINS: &[&str] = &["mainnet", "sepolia", "goerli", "holesky", "dev"]; #[cfg(feature = "telos")] /// Chains supported by telos-reth -pub const SUPPORTED_CHAINS: &[&str] = &["tevmmainnet", "tevmtestnet"]; +pub const SUPPORTED_CHAINS: &[&str] = &["tevmmainnet", "tevmtestnet", "tevmmainnet-base", "tevmtestnet-base"]; /// Helper to parse a [Duration] from seconds pub fn parse_duration_from_secs(arg: &str) -> eyre::Result { @@ -50,6 +50,10 @@ pub fn chain_spec_value_parser(s: &str) -> eyre::Result, eyre::Er "tevmmainnet" => TEVMMAINNET.clone(), #[cfg(feature = "telos")] "tevmtestnet" => TEVMTESTNET.clone(), + #[cfg(feature = "telos")] + "tevmmainnet-base" => TEVMMAINNET_BASE.clone(), + #[cfg(feature = "telos")] + "tevmtestnet-base" => TEVMTESTNET_BASE.clone(), #[cfg(not(feature = "optimism"))] "holesky" => HOLESKY.clone(), #[cfg(not(feature = "optimism"))] @@ -87,6 +91,10 @@ pub fn genesis_value_parser(s: &str) -> eyre::Result, eyre::Error "tevmmainnet" => TEVMMAINNET.clone(), #[cfg(feature = "telos")] "tevmtestnet" => TEVMTESTNET.clone(), + #[cfg(feature = "telos")] + "tevmmainnet-base" => TEVMMAINNET_BASE.clone(), + #[cfg(feature = "telos")] + "tevmtestnet-base" => TEVMTESTNET_BASE.clone(), #[cfg(not(feature = "optimism"))] "holesky" => HOLESKY.clone(), #[cfg(not(feature = "optimism"))] diff --git a/crates/node-core/src/dirs.rs b/crates/node-core/src/dirs.rs index d4a5432679f1..ca4915e24584 100644 --- a/crates/node-core/src/dirs.rs +++ b/crates/node-core/src/dirs.rs @@ -392,5 +392,17 @@ mod tests { let path = path.unwrap_or_chain_default(Chain::from_id(41)); assert!(path.as_ref().ends_with("reth/tevmtestnet"), "{:?}", path); } + + #[cfg(feature = "telos")] { + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(40)); + assert!(path.as_ref().ends_with("reth/tevmmainnet-base"), "{:?}", path); + } + + #[cfg(feature = "telos")] { + let path = MaybePlatformPath::::default(); + let path = path.unwrap_or_chain_default(Chain::from_id(41)); + assert!(path.as_ref().ends_with("reth/tevmtestnet-base"), "{:?}", path); + } } } diff --git a/crates/node-core/src/init.rs b/crates/node-core/src/init.rs index db7418a128c2..3a7f94878ff2 100644 --- a/crates/node-core/src/init.rs +++ b/crates/node-core/src/init.rs @@ -85,6 +85,9 @@ pub fn init_genesis( // insert sync stage for stage in StageId::ALL.iter() { + #[cfg(feature = "telos")] + tx.put::(stage.to_string(), reth_primitives::stage::StageCheckpoint::new(genesis.number.unwrap_or_default()))?; + #[cfg(not(feature = "telos"))] tx.put::(stage.to_string(), Default::default())?; } @@ -212,11 +215,20 @@ pub fn insert_genesis_header( ) -> ProviderResult<()> { let (header, block_hash) = chain.sealed_genesis_header().split(); + #[cfg(feature = "telos")] { + tx.put::(header.number, block_hash)?; + tx.put::(block_hash, header.number)?; + tx.put::(header.number, Default::default())?; + tx.put::(header.number, header.difficulty.into())?; + tx.put::(header.number, header)?; + } + #[cfg(not(feature = "telos"))] { tx.put::(0, block_hash)?; tx.put::(block_hash, 0)?; tx.put::(0, Default::default())?; tx.put::(0, header.difficulty.into())?; tx.put::(0, header)?; + } Ok(()) } @@ -237,7 +249,7 @@ mod tests { }; #[cfg(feature = "telos")] use reth_primitives::{ - TEVMMAINNET, TEVMMAINNET_GENESIS_HASH, TEVMTESTNET, TEVMTESTNET_GENESIS_HASH + TEVMMAINNET, TEVMMAINNET_GENESIS_HASH, TEVMTESTNET, TEVMTESTNET_GENESIS_HASH, TEVMMAINNET_BASE, TEVMMAINNET_BASE_GENESIS_HASH, TEVMTESTNET_BASE, TEVMTESTNET_BASE_GENESIS_HASH }; fn collect_table_entries( @@ -297,6 +309,27 @@ mod tests { assert_eq!(genesis_hash, TEVMTESTNET_GENESIS_HASH); } + + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmmainnet_base() { + let db = create_test_rw_db(); + let genesis_hash = init_genesis(db, TEVMMAINNET_BASE.clone()).unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMMAINNET_BASE_GENESIS_HASH); + } + + #[test] + #[cfg(feature = "telos")] + fn success_init_genesis_tevmtestnet_base() { + let db = create_test_rw_db(); + let genesis_hash = init_genesis(db, TEVMTESTNET_BASE.clone()).unwrap(); + + // actual, expected + assert_eq!(genesis_hash, TEVMTESTNET_BASE_GENESIS_HASH); + } + #[test] fn fail_init_inconsistent_db() { let db = create_test_rw_db(); diff --git a/crates/primitives/res/genesis/tevmmainnet.json b/crates/primitives/res/genesis/tevmmainnet.json index 2f3340a1ff6a..0e0d76298144 100644 --- a/crates/primitives/res/genesis/tevmmainnet.json +++ b/crates/primitives/res/genesis/tevmmainnet.json @@ -1,5 +1,5 @@ { - "nonce": "0x00", + "nonce": "0x0", "timestamp": "0x5c114972", "extraData": "0x00000024796a9998ec49fb788de51614c57276dc6151bd2328305dba5d018897", "gasLimit": "0x7fffffff", diff --git a/crates/primitives/res/genesis/tevmmainnet_base.json b/crates/primitives/res/genesis/tevmmainnet_base.json new file mode 100644 index 000000000000..de37a499648c --- /dev/null +++ b/crates/primitives/res/genesis/tevmmainnet_base.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x61782354", + "extraData": "0x0ac53eebcfa1cf139272bf58540d6dc53f0d22785f9e3d74cb9bc333b597e1bf", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0xac53ec7", + "gasUsed": "0x0", + "parentHash": "0x87bb009caefe5447b3c4beafb6cc168d031a73eb9c6bb0718b5b5972448908c2" +} \ No newline at end of file diff --git a/crates/primitives/res/genesis/tevmtestnet.json b/crates/primitives/res/genesis/tevmtestnet.json index cd9d62232553..617566e4ba85 100644 --- a/crates/primitives/res/genesis/tevmtestnet.json +++ b/crates/primitives/res/genesis/tevmtestnet.json @@ -1,5 +1,5 @@ { - "nonce": "0x00", + "nonce": "0x0", "timestamp": "0x5d55db93", "extraData": "0x000000397128c497668c241b27d1521c764156cea50bcac87892fc8916e23b24", "gasLimit": "0x7fffffff", diff --git a/crates/primitives/res/genesis/tevmtestnet_base.json b/crates/primitives/res/genesis/tevmtestnet_base.json new file mode 100644 index 000000000000..018e4f7941ed --- /dev/null +++ b/crates/primitives/res/genesis/tevmtestnet_base.json @@ -0,0 +1,13 @@ +{ + "nonce": "0x0", + "timestamp": "0x6170fef7", + "extraData": "0x0821345567cd66541778157d3936896f62a5b3fa134bb34d9708aa52f0c8c713", + "gasLimit": "0x7fffffff", + "difficulty": "0x0", + "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "coinbase": "0x0000000000000000000000000000000000000000", + "stateRoot": "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "number": "0x821341c", + "gasUsed": "0x0", + "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000" +} \ No newline at end of file diff --git a/crates/primitives/src/chain/mod.rs b/crates/primitives/src/chain/mod.rs index dee501ad195b..6d25e6093c2b 100644 --- a/crates/primitives/src/chain/mod.rs +++ b/crates/primitives/src/chain/mod.rs @@ -6,7 +6,7 @@ pub use spec::{ MAINNET, SEPOLIA, }; #[cfg(feature = "telos")] -pub use spec::{TEVMMAINNET, TEVMTESTNET}; +pub use spec::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; #[cfg(feature = "optimism")] pub use spec::{BASE_MAINNET, BASE_SEPOLIA}; diff --git a/crates/primitives/src/chain/spec.rs b/crates/primitives/src/chain/spec.rs index 4c2a2ffa6641..e923495921f8 100644 --- a/crates/primitives/src/chain/spec.rs +++ b/crates/primitives/src/chain/spec.rs @@ -222,6 +222,63 @@ pub static TEVMTESTNET: Lazy> = Lazy::new(|| { .into() }); +#[cfg(feature = "telos")] +/// The Tevmmainnet-base spec +pub static TEVMMAINNET_BASE: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(40), + genesis: serde_json::from_str(include_str!("../../res/genesis/tevmmainnet_base.json")) + .expect("Can't deserialize Tevmmainnet-base genesis json"), + genesis_hash: Some(b256!( + "757720a8e51c63ef1d4f907d6569dacaa965e91c2661345902de18af11f81063" + )), + hardforks: BTreeMap::from([ + (Hardfork::Frontier, ForkCondition::Block(180698823)), + (Hardfork::Homestead, ForkCondition::Block(180698823)), + (Hardfork::Dao, ForkCondition::Block(180698823)), + (Hardfork::Tangerine, ForkCondition::Block(180698823)), + (Hardfork::SpuriousDragon, ForkCondition::Block(180698823)), + (Hardfork::Byzantium, ForkCondition::Block(180698823)), + (Hardfork::Constantinople, ForkCondition::Block(180698823)), + (Hardfork::Petersburg, ForkCondition::Block(180698823)), + (Hardfork::Istanbul, ForkCondition::Block(180698823)), + (Hardfork::MuirGlacier, ForkCondition::Block(180698823)), + (Hardfork::Berlin, ForkCondition::Block(180698823)), + ]), + ..Default::default() + } + .into() +}); + +#[cfg(feature = "telos")] +/// The Tevmtestnet-base spec +/// TODO: Block hash not finalized yet, need to modify the parent hash +pub static TEVMTESTNET_BASE: Lazy> = Lazy::new(|| { + ChainSpec { + chain: Chain::from_id(41), + genesis: serde_json::from_str(include_str!("../../res/genesis/tevmtestnet_base.json")) + .expect("Can't deserialize Tevmtestnet-base genesis json"), + genesis_hash: Some(b256!( + "a6da3143bdeab454a923ac47589700ebe75d734f26e1f9201caa9b7268045d02" + )), + hardforks: BTreeMap::from([ + (Hardfork::Frontier, ForkCondition::Block(136393756)), + (Hardfork::Homestead, ForkCondition::Block(136393756)), + (Hardfork::Dao, ForkCondition::Block(136393756)), + (Hardfork::Tangerine, ForkCondition::Block(136393756)), + (Hardfork::SpuriousDragon, ForkCondition::Block(136393756)), + (Hardfork::Byzantium, ForkCondition::Block(136393756)), + (Hardfork::Constantinople, ForkCondition::Block(136393756)), + (Hardfork::Petersburg, ForkCondition::Block(136393756)), + (Hardfork::Istanbul, ForkCondition::Block(136393756)), + (Hardfork::MuirGlacier, ForkCondition::Block(136393756)), + (Hardfork::Berlin, ForkCondition::Block(136393756)), + ]), + ..Default::default() + } + .into() +}); + /// The Holesky spec pub static HOLESKY: Lazy> = Lazy::new(|| { ChainSpec { @@ -627,6 +684,9 @@ impl ChainSpec { Header { parent_hash: B256::ZERO, + #[cfg(feature = "telos")] + number: self.genesis.number.unwrap_or_default(), + #[cfg(not(feature = "telos"))] number: 0, transactions_root: EMPTY_TRANSACTIONS, ommers_hash: EMPTY_OMMER_ROOT_HASH, @@ -1606,7 +1666,7 @@ mod tests { use super::*; use crate::{b256, hex, trie::TrieAccount, ChainConfig, GenesisAccount}; #[cfg(feature = "telos")] - use crate::{TEVMMAINNET, TEVMTESTNET}; + use crate::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; use alloy_rlp::Encodable; use bytes::BytesMut; use std::{collections::HashMap, str::FromStr}; @@ -2348,6 +2408,26 @@ Post-merge hard forks (timestamp based): ); } + #[test] + #[cfg(feature = "telos")] + fn tevmmainnet_base_forkids() { + test_fork_ids( + &TEVMMAINNET_BASE, + &[ + ], + ); + } + + #[test] + #[cfg(feature = "telos")] + fn tevmtestnet_base_forkids() { + test_fork_ids( + &TEVMTESTNET_BASE, + &[ + ], + ); + } + #[test] fn dev_forkids() { test_fork_ids( diff --git a/crates/primitives/src/constants/mod.rs b/crates/primitives/src/constants/mod.rs index 2f9153aca82c..789707a87a68 100644 --- a/crates/primitives/src/constants/mod.rs +++ b/crates/primitives/src/constants/mod.rs @@ -128,6 +128,17 @@ pub const TEVMMAINNET_GENESIS_HASH: B256 = pub const TEVMTESTNET_GENESIS_HASH: B256 = b256!("b25034033c9ca7a40e879ddcc29cf69071a22df06688b5fe8cc2d68b4e0528f9"); +#[cfg(feature = "telos")] +/// Tevmmainnet base genesis hash. +pub const TEVMMAINNET_BASE_GENESIS_HASH: B256 = + b256!("757720a8e51c63ef1d4f907d6569dacaa965e91c2661345902de18af11f81063"); + +#[cfg(feature = "telos")] +/// Tevmtestnet base genesis hash. +/// TODO: Block hash not finalized yet, need to modify the parent hash +pub const TEVMTESTNET_BASE_GENESIS_HASH: B256 = + b256!("a6da3143bdeab454a923ac47589700ebe75d734f26e1f9201caa9b7268045d02"); + /// Holesky genesis hash. pub const HOLESKY_GENESIS_HASH: B256 = b256!("ff9006519a8ce843ac9c28549d24211420b546e12ce2d170c77a8cca7964f23d"); diff --git a/crates/primitives/src/lib.rs b/crates/primitives/src/lib.rs index 3841b88eb390..a49325c690e7 100644 --- a/crates/primitives/src/lib.rs +++ b/crates/primitives/src/lib.rs @@ -57,7 +57,7 @@ pub use chain::{ }; #[cfg(feature = "telos")] pub use chain::{ - TEVMMAINNET, TEVMTESTNET, + TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE }; pub use compression::*; pub use constants::{ @@ -66,7 +66,7 @@ pub use constants::{ }; #[cfg(feature = "telos")] pub use constants::{ - TEVMMAINNET_GENESIS_HASH, TEVMTESTNET_GENESIS_HASH, + TEVMMAINNET_GENESIS_HASH, TEVMTESTNET_GENESIS_HASH, TEVMMAINNET_BASE_GENESIS_HASH, TEVMTESTNET_BASE_GENESIS_HASH, }; pub use error::{GotExpected, GotExpectedBoxed}; pub use genesis::{ChainConfig, Genesis, GenesisAccount}; diff --git a/crates/primitives/src/proofs.rs b/crates/primitives/src/proofs.rs index 90f0e4cabfca..12ddca4f4f73 100644 --- a/crates/primitives/src/proofs.rs +++ b/crates/primitives/src/proofs.rs @@ -266,7 +266,7 @@ mod tests { GOERLI, HOLESKY, MAINNET, SEPOLIA, }; #[cfg(feature = "telos")] - use crate::{TEVMMAINNET, TEVMTESTNET}; + use crate::{TEVMMAINNET, TEVMTESTNET, TEVMMAINNET_BASE, TEVMTESTNET_BASE}; use alloy_primitives::b256; use alloy_rlp::Decodable; use std::collections::HashMap; @@ -688,6 +688,26 @@ mod tests { ); } + #[cfg(feature = "telos")] { + let expected_tevmmainnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmmainnet_base_state_root = state_root_ref_unhashed(&TEVMMAINNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmmainnet_base_state_root, calculated_tevmmainnet_base_state_root, + "tevmmainnet-base state root mismatch" + ); + } + + #[cfg(feature = "telos")] { + let expected_tevmtestnet_base_state_root = + b256!("56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421"); + let calculated_tevmtestnet_base_state_root = state_root_ref_unhashed(&TEVMTESTNET_BASE.genesis.alloc); + assert_eq!( + expected_tevmtestnet_base_state_root, calculated_tevmtestnet_base_state_root, + "tevmtestnet-base state root mismatch" + ); + } + let expected_holesky_state_root = b256!("69d8c9d72f6fa4ad42d4702b433707212f90db395eb54dc20bc85de253788783"); let calculated_holesky_state_root = state_root_ref_unhashed(&HOLESKY.genesis.alloc); diff --git a/crates/storage/provider/src/providers/database/provider.rs b/crates/storage/provider/src/providers/database/provider.rs index f07760ff318b..babf07971519 100644 --- a/crates/storage/provider/src/providers/database/provider.rs +++ b/crates/storage/provider/src/providers/database/provider.rs @@ -55,7 +55,6 @@ use std::{ sync::{mpsc, Arc}, time::{Duration, Instant}, }; -use revm::interpreter::instructions::bitwise::not; use tracing::{debug, warn}; /// A [`DatabaseProvider`] that holds a read-only database transaction. From ac9ab81058d233f9e7434f217f4fc9a23cb1ac0b Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Sun, 11 Feb 2024 01:19:31 +0330 Subject: [PATCH 2/6] Modify the recover_sender function to extract the sender from 's' field of signature --- crates/primitives/src/transaction/mod.rs | 9 ++++++++- crates/primitives/src/transaction/signature.rs | 14 +++++++++++--- crates/stages/src/stages/sender_recovery.rs | 2 +- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/crates/primitives/src/transaction/mod.rs b/crates/primitives/src/transaction/mod.rs index f54b9d25cef8..5c736c879228 100644 --- a/crates/primitives/src/transaction/mod.rs +++ b/crates/primitives/src/transaction/mod.rs @@ -989,6 +989,13 @@ impl TransactionSigned { if let Transaction::Deposit(TxDeposit { from, .. }) = self.transaction { return Some(from) } + #[cfg(feature = "telos")] + if self.transaction.chain_id() == Some(3) { + let mut s_bytes: [u8; 20] = [0; 20]; + s_bytes.copy_from_slice(&self.signature.s.to_be_bytes::<32>()[0..20]); + let address = Address::new(s_bytes); + return Some(address); + } let signature_hash = self.signature_hash(); self.signature.recover_signer(signature_hash) } @@ -1006,7 +1013,7 @@ impl TransactionSigned { return Some(from) } let signature_hash = self.signature_hash(); - self.signature.recover_signer_unchecked(signature_hash) + self.signature.recover_signer_unchecked(signature_hash, #[cfg(feature = "telos")] self.chain_id()) } /// Recovers a list of signers from a transaction list iterator. diff --git a/crates/primitives/src/transaction/signature.rs b/crates/primitives/src/transaction/signature.rs index 3cbfa1c746c8..340c33b91aaf 100644 --- a/crates/primitives/src/transaction/signature.rs +++ b/crates/primitives/src/transaction/signature.rs @@ -141,7 +141,15 @@ impl Signature { /// Using this for signature validation will succeed, even if the signature is malleable or not /// compliant with EIP-2. This is provided for compatibility with old signatures which have /// large `s` values. - pub fn recover_signer_unchecked(&self, hash: B256) -> Option
{ + pub fn recover_signer_unchecked(&self, hash: B256, #[cfg(feature = "telos")] chain_id: Option) -> Option
{ + #[cfg(feature = "telos")] + if chain_id == Some(3) { + let mut s_bytes: [u8; 20] = [0; 20]; + s_bytes.copy_from_slice(&self.s.to_be_bytes::<32>()[0..20]); + let address = Address::new(s_bytes); + return Some(address); + } + let mut sig: [u8; 65] = [0; 65]; sig[0..32].copy_from_slice(&self.r.to_be_bytes::<32>()); @@ -163,7 +171,7 @@ impl Signature { return None } - self.recover_signer_unchecked(hash) + self.recover_signer_unchecked(hash, #[cfg(feature = "telos")] None) } /// Turn this signature into its byte @@ -350,6 +358,6 @@ mod tests { assert!(signature.recover_signer(hash).is_none()); // use unchecked, ensure it succeeds (the signature is valid if not for EIP-2) - assert!(signature.recover_signer_unchecked(hash).is_some()); + assert!(signature.recover_signer_unchecked(hash, #[cfg(feature = "telos")] tx.chain_id()).is_some()); } } diff --git a/crates/stages/src/stages/sender_recovery.rs b/crates/stages/src/stages/sender_recovery.rs index a758b9b6bc09..5c5a3d9feda6 100644 --- a/crates/stages/src/stages/sender_recovery.rs +++ b/crates/stages/src/stages/sender_recovery.rs @@ -205,7 +205,7 @@ fn recover_sender( // backwards-compatible. let sender = tx .signature - .recover_signer_unchecked(keccak256(rlp_buf)) + .recover_signer_unchecked(keccak256(rlp_buf), #[cfg(feature = "telos")] tx.chain_id()) .ok_or(SenderRecoveryStageError::FailedRecovery(FailedSenderRecoveryError { tx: tx_id }))?; Ok((tx_id, sender)) From 5d90d8daa5a1896ecd802e5d9bad14833c97fd51 Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Tue, 27 Feb 2024 11:52:04 +0330 Subject: [PATCH 3/6] Disable block beneficiary rewarding --- crates/consensus/common/src/calc.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/crates/consensus/common/src/calc.rs b/crates/consensus/common/src/calc.rs index d280d704431b..eacc1e3c3ba2 100644 --- a/crates/consensus/common/src/calc.rs +++ b/crates/consensus/common/src/calc.rs @@ -24,6 +24,10 @@ pub fn base_block_reward( block_difficulty: U256, total_difficulty: U256, ) -> Option { + #[cfg(feature = "telos")] + if chain_spec.chain == Chain::from_id(40) || chain_spec.chain == Chain::from_id(41) { + return None + } if chain_spec.chain == Chain::goerli() || chain_spec.fork(Hardfork::Paris).active_at_ttd(total_difficulty, block_difficulty) { From 41d5df6b450af24d0f17285ff217eb681425b820 Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Sat, 9 Mar 2024 23:56:15 +0330 Subject: [PATCH 4/6] Skip the total difficulty check when changing the head using Engine API --- crates/blockchain-tree/src/blockchain_tree.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/crates/blockchain-tree/src/blockchain_tree.rs b/crates/blockchain-tree/src/blockchain_tree.rs index 0a4ec44e9742..299c35b56c7f 100644 --- a/crates/blockchain-tree/src/blockchain_tree.rs +++ b/crates/blockchain-tree/src/blockchain_tree.rs @@ -937,6 +937,7 @@ impl BlockchainTree { hash: *block_hash, }), )?; + #[cfg(not(feature = "telos"))] if !self .externals .provider_factory From 7bb43e7439b01f73365c4d08f48fe2cfae207bb8 Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Mon, 11 Mar 2024 09:02:10 +0330 Subject: [PATCH 5/6] Embed get_account bug of EVM contract --- Cargo.lock | 506 +++++++++++++-------------- crates/primitives/src/revm/env.rs | 2 + crates/rpc/rpc/src/eth/revm_utils.rs | 2 + 3 files changed, 253 insertions(+), 257 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index df357dadd4d6..67f1df7ad69c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -88,9 +88,9 @@ dependencies = [ [[package]] name = "ahash" -version = "0.8.9" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d713b3834d76b85304d4d525563c1276e2e30dc97cc67bfb4585a4a29fc2c89f" +checksum = "e89da841a80418a9b391ebaea17f5c112ffaaa96f621d2c285b5174da76b9011" dependencies = [ "cfg-if", "getrandom 0.2.12", @@ -140,23 +140,23 @@ checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" [[package]] name = "alloy-chains" -version = "0.1.12" +version = "0.1.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "146dc3f33a9e282751a62ddd6687292c504605cc285a49500541e5d1e5b7617b" +checksum = "e96c81b05c893348760f232c4cc6a6a77fd91cfb09885d4eaad25cd03bd7732e" dependencies = [ "alloy-rlp", "arbitrary", "num_enum 0.7.2", "proptest", "serde", - "strum 0.26.1", + "strum 0.26.2", ] [[package]] name = "alloy-dyn-abi" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13b1a44ed6b4126e4818d20c9e48176ae9d6d4fcbe6c909f8cd0bf050eb56fd8" +checksum = "2919acdad13336bc5dc26b636cdd6892c2f27fb0d4a58320a00c2713cf6a4e9a" dependencies = [ "alloy-json-abi", "alloy-primitives", @@ -167,7 +167,7 @@ dependencies = [ "itoa", "serde", "serde_json", - "winnow 0.5.40", + "winnow 0.6.5", ] [[package]] @@ -192,9 +192,9 @@ dependencies = [ [[package]] name = "alloy-json-abi" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30c6a6c5140fc762edfe55349f9ddefa821f4b7f2339cef582de911a3f1fb6d3" +checksum = "24ed0f2a6c3a1c947b4508522a53a190dba8f94dcd4e3e1a5af945a498e78f2f" dependencies = [ "alloy-primitives", "alloy-sol-type-parser", @@ -216,9 +216,9 @@ dependencies = [ [[package]] name = "alloy-primitives" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ef197eb250c64962003cb08b90b17f0882c192f4a6f2f544809d424fd7cb0e7d" +checksum = "600d34d8de81e23b6d909c094e23b3d357e01ca36b78a8c5424c501eedbe86f0" dependencies = [ "alloy-rlp", "arbitrary", @@ -260,7 +260,7 @@ checksum = "1a047897373be4bbb0224c1afdabca92648dc57a9c9ef6e7b0be3aff7a859c83" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -310,36 +310,36 @@ dependencies = [ [[package]] name = "alloy-sol-macro" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e92100dee7fd1e44abbe0ef6607f18758cf0ad4e483f4c65ff5c8d85428a6d" +checksum = "e86ec0a47740b20bc5613b8712d0d321d031c4efc58e9645af96085d5cccfc27" dependencies = [ "const-hex", "dunce", "heck", - "indexmap 2.2.3", + "indexmap 2.2.5", "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "syn-solidity", "tiny-keccak", ] [[package]] name = "alloy-sol-type-parser" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d146adca22a853b5aaaa98a6c78bd9d8f1d627ca7b01d170edccf45430e9b2cb" +checksum = "0045cc89524e1451ccf33e8581355b6027ac7c6e494bb02959d4213ad0d8e91d" dependencies = [ - "winnow 0.5.40", + "winnow 0.6.5", ] [[package]] name = "alloy-sol-types" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e7c6a8c492b1d6a4f92a8fc6a13cf39473978dd7d459d7221969ce5a73d97cd" +checksum = "ad09ec5853fa700d12d778ad224dcdec636af424d29fad84fb9a2f16a5b0ef09" dependencies = [ "alloy-primitives", "alloy-sol-macro", @@ -390,9 +390,9 @@ checksum = "4b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299" [[package]] name = "anstream" -version = "0.6.12" +version = "0.6.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96b09b5178381e0874812a9b157f7fe84982617e48f71f4e3235482775e5b540" +checksum = "d96bd03f33fe50a863e394ee9718a706f988b9079b20c3784fb726e7678b62fb" dependencies = [ "anstyle", "anstyle-parse", @@ -494,7 +494,7 @@ dependencies = [ "proc-macro-error", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -711,7 +711,7 @@ checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -722,7 +722,7 @@ checksum = "c980ee35e870bd1a4d2c8294d4c04d0499e67bca1e4b5cefcc693c2fa00caea9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -759,13 +759,13 @@ dependencies = [ [[package]] name = "auto_impl" -version = "1.1.2" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "823b8bb275161044e2ac7a25879cb3e2480cb403e3943022c7c769c599b756aa" +checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -776,9 +776,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "backon" -version = "0.4.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c79c8ef183b8b663e8cb19cf92fb7d98c56739977bd47eae2de2717bd5de2c2c" +checksum = "c491fa80d69c03084223a4e73c378dd9f9a1e612eb54051213f88b2d5249b458" dependencies = [ "fastrand 2.0.1", "futures-core", @@ -873,26 +873,6 @@ dependencies = [ "serde", ] -[[package]] -name = "bindgen" -version = "0.68.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "726e4313eb6ec35d2730258ad4e15b547ee75d6afaa1361a922e78e59b7d8078" -dependencies = [ - "bitflags 2.4.2", - "cexpr", - "clang-sys", - "lazy_static", - "lazycell", - "peeking_take_while", - "proc-macro2", - "quote", - "regex", - "rustc-hash", - "shlex", - "syn 2.0.51", -] - [[package]] name = "bindgen" version = "0.69.4" @@ -910,7 +890,7 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -1020,7 +1000,7 @@ dependencies = [ "bitflags 2.4.2", "boa_interner", "boa_macros", - "indexmap 2.2.3", + "indexmap 2.2.5", "num-bigint", "rustc-hash", ] @@ -1043,7 +1023,7 @@ dependencies = [ "dashmap", "fast-float", "icu_normalizer", - "indexmap 2.2.3", + "indexmap 2.2.5", "itertools 0.11.0", "num-bigint", "num-integer", @@ -1099,7 +1079,7 @@ dependencies = [ "boa_gc", "boa_macros", "hashbrown 0.14.3", - "indexmap 2.2.3", + "indexmap 2.2.5", "once_cell", "phf", "rustc-hash", @@ -1114,7 +1094,7 @@ checksum = "005fa0c5bd20805466dda55eb34cd709bb31a2592bb26927b47714eeed6914d8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "synstructure", ] @@ -1202,9 +1182,9 @@ dependencies = [ [[package]] name = "bumpalo" -version = "3.15.3" +version = "3.15.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ea184aa71bb362a1157c896979544cc23974e08fd265f29ea96b59f0b4a555b" +checksum = "7ff69b9dd49fd426c69a0db9fc04dd934cdb6645ff000864d98f7e2af8830eaa" [[package]] name = "byte-slice-cast" @@ -1318,9 +1298,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.34" +version = "0.4.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bc015644b92d5890fab7489e49d21f879d5c990186827d42ec511919404f38b" +checksum = "8eaf5903dcbc0a39312feb77df2ff4c76387d591b9fc7b04a238dcf8bb62639a" dependencies = [ "android-tzdata", "iana-time-zone", @@ -1328,7 +1308,7 @@ dependencies = [ "num-traits", "serde", "wasm-bindgen", - "windows-targets 0.52.3", + "windows-targets 0.52.4", ] [[package]] @@ -1390,9 +1370,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.1" +version = "4.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c918d541ef2913577a0f9566e9ce27cb35b6df072075769e0b26cb5a554520da" +checksum = "b230ab84b0ffdf890d5a10abdbc8b83ae1c4918275daea1ab8801f71536b2651" dependencies = [ "clap_builder", "clap_derive", @@ -1400,9 +1380,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.1" +version = "4.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f3e7391dad68afb0c2ede1bf619f579a3dc9c2ec67f089baa397123a2f3d1eb" +checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" dependencies = [ "anstream", "anstyle", @@ -1419,7 +1399,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -1453,7 +1433,7 @@ dependencies = [ "quote", "serde", "similar-asserts", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -1537,9 +1517,9 @@ dependencies = [ [[package]] name = "confy" -version = "0.6.0" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "15d296c475c6ed4093824c28e222420831d27577aaaf0a1163a3b7fc35b248a5" +checksum = "45b1f4c00870f07dc34adcac82bb6a72cc5aabca8536ba1797e01df51d2ce9a0" dependencies = [ "directories", "serde", @@ -1561,9 +1541,9 @@ dependencies = [ [[package]] name = "const-hex" -version = "1.11.1" +version = "1.11.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efbd12d49ab0eaf8193ba9175e45f56bbc2e4b27d57b8cfe62aa47942a46b9a9" +checksum = "b37dae8c8ded08d5ec72caa1b4204a5344047cd4a2c7387e3d150020abfbc1c9" dependencies = [ "cfg-if", "cpufeatures", @@ -1580,9 +1560,9 @@ checksum = "c2459377285ad874054d797f3ccebf984978aa39129f6eafde5cdc8315b612f8" [[package]] name = "const-str" -version = "0.5.6" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aca749d3d3f5b87a0d6100509879f9cf486ab510803a4a4e1001da1ff61c2bd6" +checksum = "3618cccc083bb987a415d85c02ca6c9994ea5b44731ec28b9ecf09658655fba9" [[package]] name = "convert_case" @@ -1703,9 +1683,9 @@ checksum = "7059fff8937831a9ae6f0fe4d658ffabf58f2ca96aa9dec1c889f936f705f216" [[package]] name = "crossbeam-channel" -version = "0.5.11" +version = "0.5.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "176dc175b78f56c0f321911d9c8eb2b77a78a4860b9c19db83835fea1a46649b" +checksum = "ab3db02a9c5b5121e1e42fbdb1aeb65f5e02624cc58c43f2884c6ccac0b82f95" dependencies = [ "crossbeam-utils", ] @@ -1854,7 +1834,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -1961,7 +1941,7 @@ dependencies = [ "proc-macro2", "quote", "strsim 0.10.0", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -1994,7 +1974,7 @@ checksum = "a668eda54683121533a393014d8692171709ff57a7d61f187b6e782719f8933f" dependencies = [ "darling_core 0.20.8", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2081,7 +2061,7 @@ checksum = "67e77553c4162a157adbf834ebae5b415acbecbeafc7a74b0e886657506a7611" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2209,7 +2189,7 @@ dependencies = [ "aes-gcm", "arrayvec", "delay_map", - "enr", + "enr 0.9.1", "fnv", "futures", "hashlink", @@ -2238,7 +2218,7 @@ checksum = "487585f4d0c6655fe74905e2504d8ad6908e4db67f744eb140876906c2f3175d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2421,6 +2401,24 @@ dependencies = [ "zeroize", ] +[[package]] +name = "enr" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2a3d8dc56e02f954cac8eb489772c552c473346fc34f67412bb6244fd647f7e4" +dependencies = [ + "base64 0.21.7", + "bytes", + "hex", + "k256", + "log", + "rand 0.8.5", + "rlp", + "serde", + "sha3", + "zeroize", +] + [[package]] name = "enum-as-inner" version = "0.3.4" @@ -2442,7 +2440,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2455,7 +2453,7 @@ dependencies = [ "num-traits", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2466,7 +2464,7 @@ checksum = "6fd000fd6988e73bbe993ea3db9b1aa64906ab88766d654973924340c8cddb42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -2580,9 +2578,9 @@ dependencies = [ [[package]] name = "ethers-contract" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43304317c7f776876e47f2f637859f6d0701c1ec7930a150f169d5fbe7d76f5a" +checksum = "6fceafa3578c836eeb874af87abacfb041f92b4da0a78a5edd042564b8ecdaaa" dependencies = [ "const-hex", "ethers-contract-abigen", @@ -2599,9 +2597,9 @@ dependencies = [ [[package]] name = "ethers-contract-abigen" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f9f96502317bf34f6d71a3e3d270defaa9485d754d789e15a8e04a84161c95eb" +checksum = "04ba01fbc2331a38c429eb95d4a570166781f14290ef9fdb144278a90b5a739b" dependencies = [ "Inflector", "const-hex", @@ -2614,16 +2612,16 @@ dependencies = [ "regex", "serde", "serde_json", - "syn 2.0.51", + "syn 2.0.52", "toml", "walkdir", ] [[package]] name = "ethers-contract-derive" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "452ff6b0a64507ce8d67ffd48b1da3b42f03680dcf5382244e9c93822cbbf5de" +checksum = "87689dcabc0051cde10caaade298f9e9093d65f6125c14575db3fd8c669a168f" dependencies = [ "Inflector", "const-hex", @@ -2632,14 +2630,14 @@ dependencies = [ "proc-macro2", "quote", "serde_json", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] name = "ethers-core" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aab3cef6cc1c9fd7f787043c81ad3052eff2b96a3878ef1526aa446311bdbfc9" +checksum = "82d80cc6ad30b14a48ab786523af33b37f28a8623fc06afd55324816ef18fb1f" dependencies = [ "arrayvec", "bytes", @@ -2657,8 +2655,8 @@ dependencies = [ "rlp", "serde", "serde_json", - "strum 0.25.0", - "syn 2.0.51", + "strum 0.26.2", + "syn 2.0.52", "tempfile", "thiserror", "tiny-keccak", @@ -2667,9 +2665,9 @@ dependencies = [ [[package]] name = "ethers-middleware" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "145211f34342487ef83a597c1e69f0d3e01512217a7c72cc8a25931854c7dca0" +checksum = "48f9fdf09aec667c099909d91908d5eaf9be1bd0e2500ba4172c1d28bfaa43de" dependencies = [ "async-trait", "auto_impl", @@ -2693,16 +2691,16 @@ dependencies = [ [[package]] name = "ethers-providers" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb6b15393996e3b8a78ef1332d6483c11d839042c17be58decc92fa8b1c3508a" +checksum = "6434c9a33891f1effc9c75472e12666db2fa5a0fec4b29af6221680a6fe83ab2" dependencies = [ "async-trait", "auto_impl", "base64 0.21.7", "bytes", "const-hex", - "enr", + "enr 0.10.0", "ethers-core", "futures-channel", "futures-core", @@ -2731,9 +2729,9 @@ dependencies = [ [[package]] name = "ethers-signers" -version = "2.0.13" +version = "2.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3b125a103b56aef008af5d5fb48191984aa326b50bfd2557d231dc499833de3" +checksum = "228875491c782ad851773b652dd8ecac62cda8571d3bc32a5853644dd26766c2" dependencies = [ "async-trait", "coins-bip32", @@ -3012,7 +3010,7 @@ checksum = "87750cf4b7a4c0625b1529e4c543c2182106e4dedc60a2a6455e00d212c489ac" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -3188,7 +3186,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap 2.2.3", + "indexmap 2.2.5", "slab", "tokio", "tokio-util", @@ -3273,9 +3271,9 @@ checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" [[package]] name = "hermit-abi" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "379dada1584ad501b383485dd706b8afb7a70fcbc7f4da7d780638a5a6124a60" +checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" [[package]] name = "hex" @@ -3323,9 +3321,9 @@ dependencies = [ [[package]] name = "http" -version = "0.2.11" +version = "0.2.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8947b1a6fad4393052c7ba1f4cd97bed3e953a95c79c92ad9b051a04611d9fbb" +checksum = "601cbb57e577e2f5ef5be8e7b83f0f63994f25aa94d673e54a92d5c516d101f1" dependencies = [ "bytes", "fnv", @@ -3747,9 +3745,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.2.3" +version = "2.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233cf39063f058ea2caae4091bf4a3ef70a653afbc026f5c4a4135d114e3c177" +checksum = "7b0b929d511467233429c45a44ac1dcaa21ba0f5ba11e4879e6ed28ddb4f9df4" dependencies = [ "equivalent", "hashbrown 0.14.3", @@ -3775,7 +3773,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "321f0f839cd44a4686e9504b0a62b4d69a50b62072144c71c68f5873c167b8d9" dependencies = [ "ahash", - "indexmap 2.2.3", + "indexmap 2.2.5", "is-terminal", "itoa", "log", @@ -3919,9 +3917,9 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.68" +version = "0.3.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "406cda4b368d531c842222cf9d2600a9a4acce8d29423695379c6868a143a9ee" +checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" dependencies = [ "wasm-bindgen", ] @@ -4176,12 +4174,12 @@ dependencies = [ [[package]] name = "libloading" -version = "0.8.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c571b676ddfc9a8c12f1f3d3085a7b163966a8fd8098a90640953ce5f6170161" +checksum = "0c2a198fb6b0eada2a8df47933734e6d35d350665a33a3593d7164fa52c75c19" dependencies = [ "cfg-if", - "windows-sys 0.48.0", + "windows-targets 0.52.4", ] [[package]] @@ -4192,11 +4190,11 @@ checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" [[package]] name = "libproc" -version = "0.14.2" +version = "0.14.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "229004ebba9d1d5caf41623f1523b6d52abb47d9f6ab87f7e6fc992e3b854aef" +checksum = "8e8dd173fc513e807c8d8ca0ecef5db7e98aad0f87c60c80e5ecce83ac793b8e" dependencies = [ - "bindgen 0.68.1", + "bindgen", "errno", "libc", ] @@ -4251,9 +4249,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "lru" @@ -4386,7 +4384,7 @@ checksum = "38b4faf00617defe497754acde3024865bc143d44a86799b24e191ecff91354f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -4476,9 +4474,9 @@ dependencies = [ [[package]] name = "mio" -version = "0.8.10" +version = "0.8.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f3d0b296e374a4e6f3c7b0a1f5a51d748a0d34c85e7dc48fc3fa9a87657fe09" +checksum = "a4a650543ca06a924e8b371db273b2756685faae30f8487da1b56505a8f78b0c" dependencies = [ "libc", "log", @@ -4734,7 +4732,7 @@ dependencies = [ "proc-macro-crate 1.3.1", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -4746,7 +4744,7 @@ dependencies = [ "proc-macro-crate 3.1.0", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -4799,9 +4797,9 @@ checksum = "0ab1bc2a289d34bd04a330323ac98a1b4bc82c9d9fcb1e66b63caa84da26b575" [[package]] name = "opaque-debug" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" +checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" [[package]] name = "open-fastrlp" @@ -4851,7 +4849,7 @@ checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -5035,12 +5033,6 @@ dependencies = [ "hmac", ] -[[package]] -name = "peeking_take_while" -version = "0.1.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "19b17cddbe7ec3f8bc800887bab5e717348c95ea2ca0b1bf0837fb964dc67099" - [[package]] name = "pem" version = "1.1.1" @@ -5067,9 +5059,9 @@ checksum = "e3148f5046208a5d56bcfc03053e3ca6334e51da8dfb19b6cdc8b306fae3283e" [[package]] name = "pest" -version = "2.7.7" +version = "2.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "219c0dcc30b6a27553f9cc242972b67f75b60eb0db71f0b5462f38b058c41546" +checksum = "56f8023d0fb78c8e03784ea1c7f3fa36e68a723138990b8d5a47d916b651e7a8" dependencies = [ "memchr", "thiserror", @@ -5129,7 +5121,7 @@ dependencies = [ "phf_shared", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -5143,22 +5135,22 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0302c4a0442c456bd56f841aee5c3bfd17967563f6fadc9ceb9f9c23cf3807e0" +checksum = "b6bf43b791c5b9e34c3d182969b4abb522f9343702850a2e57f460d00d09b4b3" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.1.4" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "266c042b60c9c76b8d53061e52b2e0d1116abc57cefc8c5cd671619a56ac3690" +checksum = "2f38a4412a78282e09a2cf38d195ea5420d15ba0602cb375210efbc877243965" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -5353,7 +5345,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a41cf62165e97c7f814d2221421dbb9afcbcdb0a88068e5ea206e19951c2cbb5" dependencies = [ "proc-macro2", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -5684,9 +5676,9 @@ dependencies = [ [[package]] name = "rayon" -version = "1.8.1" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa7237101a77a10773db45d62004a272517633fbcc3df19d96455ede1122e051" +checksum = "e4963ed1bc86e4f3ee217022bd855b297cef07fb9eac5dfa1f788b220b49b3bd" dependencies = [ "either", "rayon-core", @@ -5739,7 +5731,7 @@ checksum = "b62dbe01f0b06f9d8dc7d49e05a0785f153b00b2c227856282f671e0318c9b15" dependencies = [ "aho-corasick 1.1.2", "memchr", - "regex-automata 0.4.5", + "regex-automata 0.4.6", "regex-syntax 0.8.2", ] @@ -5754,9 +5746,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5bb987efffd3c6d0d8f5f89510bb458559eab11e4f869acb20bf845e016259cd" +checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" dependencies = [ "aho-corasick 1.1.2", "memchr", @@ -5787,9 +5779,9 @@ dependencies = [ [[package]] name = "reqwest" -version = "0.11.24" +version = "0.11.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6920094eb85afde5e4a138be3f2de8bbdf28000f0029e72c45025a56b042251" +checksum = "0eea5a9eb898d3783f17c6407670e3592fd174cb81a10e51d4c37f49450b9946" dependencies = [ "base64 0.21.7", "bytes", @@ -6119,7 +6111,7 @@ dependencies = [ "rustc-hash", "serde", "serde_json", - "strum 0.26.1", + "strum 0.26.2", "tempfile", "test-fuzz", "thiserror", @@ -6131,7 +6123,7 @@ version = "0.1.0-alpha.21" dependencies = [ "alloy-rlp", "discv5", - "enr", + "enr 0.9.1", "generic-array", "parking_lot 0.12.1", "rand 0.8.5", @@ -6156,7 +6148,7 @@ dependencies = [ "alloy-rlp", "async-trait", "data-encoding", - "enr", + "enr 0.9.1", "linked_hash_set", "parking_lot 0.12.1", "reth-net-common", @@ -6344,7 +6336,7 @@ dependencies = [ "criterion", "dashmap", "derive_more", - "indexmap 2.2.3", + "indexmap 2.2.5", "libc", "libffi", "parking_lot 0.12.1", @@ -6361,7 +6353,7 @@ dependencies = [ name = "reth-mdbx-sys" version = "0.1.0-alpha.21" dependencies = [ - "bindgen 0.69.4", + "bindgen", "cc", "libc", ] @@ -6387,7 +6379,7 @@ dependencies = [ "quote", "regex", "serial_test", - "syn 2.0.51", + "syn 2.0.52", "trybuild", ] @@ -6425,7 +6417,7 @@ dependencies = [ "auto_impl", "criterion", "derive_more", - "enr", + "enr 0.9.1", "ethers-core", "ethers-middleware", "ethers-providers", @@ -6758,7 +6750,7 @@ dependencies = [ "serde", "serde_json", "sha2", - "strum 0.26.1", + "strum 0.26.2", "sucds 0.6.0", "tempfile", "test-fuzz", @@ -6791,7 +6783,7 @@ dependencies = [ "reth-primitives", "reth-trie", "revm", - "strum 0.26.1", + "strum 0.26.2", "tempfile", "tokio", "tokio-stream", @@ -6949,7 +6941,7 @@ dependencies = [ "reth-transaction-pool", "serde", "serde_json", - "strum 0.26.1", + "strum 0.26.2", "thiserror", "tokio", "tower", @@ -7099,7 +7091,7 @@ dependencies = [ [[package]] name = "reth-telos" -version = "0.1.0-alpha.20" +version = "0.1.0-alpha.21" dependencies = [ "antelope-client", "clap", @@ -7196,7 +7188,7 @@ dependencies = [ [[package]] name = "revm" version = "6.1.0" -source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#8c0cbbf6b1e287d9be250a841a049b8d1610b54e" +source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#a140a195f7a18eee42f268de389c6c42e3f8e268" dependencies = [ "auto_impl", "cfg-if", @@ -7227,7 +7219,7 @@ dependencies = [ [[package]] name = "revm-interpreter" version = "3.1.0" -source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#8c0cbbf6b1e287d9be250a841a049b8d1610b54e" +source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#a140a195f7a18eee42f268de389c6c42e3f8e268" dependencies = [ "revm-primitives", "serde", @@ -7236,7 +7228,7 @@ dependencies = [ [[package]] name = "revm-precompile" version = "4.1.0" -source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#8c0cbbf6b1e287d9be250a841a049b8d1610b54e" +source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#a140a195f7a18eee42f268de389c6c42e3f8e268" dependencies = [ "aurora-engine-modexp", "c-kzg", @@ -7252,7 +7244,7 @@ dependencies = [ [[package]] name = "revm-primitives" version = "2.1.0" -source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#8c0cbbf6b1e287d9be250a841a049b8d1610b54e" +source = "git+https://github.com/telosnetwork/telos-revm?branch=telos-main#a140a195f7a18eee42f268de389c6c42e3f8e268" dependencies = [ "alloy-primitives", "auto_impl", @@ -7386,9 +7378,9 @@ dependencies = [ [[package]] name = "ruint" -version = "1.11.1" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608a5726529f2f0ef81b8fde9873c4bb829d6b5b5ca6be4d97345ddf0749c825" +checksum = "49b1d9521f889713d1221270fdd63370feca7e5c71a18745343402fa86e4f04f" dependencies = [ "alloy-rlp", "arbitrary", @@ -7412,9 +7404,9 @@ dependencies = [ [[package]] name = "ruint-macro" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e666a5496a0b2186dbcd0ff6106e29e093c15591bde62c20d3842007c6978a09" +checksum = "f86854cf50259291520509879a5c294c3c9a4c334e9ff65071c51e42ef1e2343" [[package]] name = "rustc-demangle" @@ -7777,7 +7769,7 @@ checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -7786,7 +7778,7 @@ version = "1.0.114" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c5f09b1bd632ef549eaa9f60a1f8de742bdbc698e6cee2095fc84dde5f549ae0" dependencies = [ - "indexmap 2.2.3", + "indexmap 2.2.5", "itoa", "ryu", "serde", @@ -7834,7 +7826,7 @@ dependencies = [ "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.2.3", + "indexmap 2.2.5", "serde", "serde_derive", "serde_json", @@ -7851,7 +7843,7 @@ dependencies = [ "darling 0.20.8", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -7876,7 +7868,7 @@ checksum = "b93fb4adc70021ac1b47f7d45e8cc4169baaa7ea58483bc5b721d19a26202212" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8188,11 +8180,11 @@ dependencies = [ [[package]] name = "strum" -version = "0.26.1" +version = "0.26.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "723b93e8addf9aa965ebe2d11da6d7540fa2283fcea14b3371ff055f7ba13f5f" +checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29" dependencies = [ - "strum_macros 0.26.1", + "strum_macros 0.26.2", ] [[package]] @@ -8205,20 +8197,20 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] name = "strum_macros" -version = "0.26.1" +version = "0.26.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a3417fc93d76740d974a01654a09777cb500428cc874ca9f45edfe0c4d4cd18" +checksum = "c6cf59daf282c0a494ba14fd21610a0325f9f90ec9d1231dea26bcb1d696c946" dependencies = [ "heck", "proc-macro2", "quote", "rustversion", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8295,9 +8287,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.51" +version = "2.0.52" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ab617d94515e94ae53b8406c628598680aa0c9587474ecbe58188f7b345d66c" +checksum = "b699d15b36d1f02c3e7c69f8ffef53de37aefae075d8488d4ba1a7788d574a07" dependencies = [ "proc-macro2", "quote", @@ -8306,14 +8298,14 @@ dependencies = [ [[package]] name = "syn-solidity" -version = "0.6.3" +version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e656cbcef8a77543b5accbd76f60f9e0bc4be364b0aba4263a6f313f8a355511" +checksum = "cb3d0961cd53c23ea94eeec56ba940f636f6394788976e9f16ca5ee0aca7464a" dependencies = [ "paste", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8330,25 +8322,25 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] name = "system-configuration" -version = "0.5.1" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3a3adc5c275d719af8cb4272ea1c4a6d668a777f37e115f6d11ddbc1c8e0e7" +checksum = "658bc6ee10a9b4fcf576e9b0819d95ec16f4d2c02d39fd83ac1c8789785c4a42" dependencies = [ - "bitflags 1.3.2", + "bitflags 2.4.2", "core-foundation", "system-configuration-sys", ] [[package]] name = "system-configuration-sys" -version = "0.5.0" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a75fb188eb626b924683e3b95e3a48e63551fcfb51949de2f06a9d91dbee93c9" +checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4" dependencies = [ "core-foundation-sys", "libc", @@ -8422,7 +8414,7 @@ dependencies = [ "prettyplease", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8461,7 +8453,7 @@ checksum = "a953cb265bef375dae3de6663da4d3804eee9682ea80d8e2542529b73c531c81" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8588,7 +8580,7 @@ checksum = "5b8a1e28f2deaa14e508979454cb3a223b10b938b45af148bc0986de36f1923b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8678,7 +8670,7 @@ version = "0.19.15" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" dependencies = [ - "indexmap 2.2.3", + "indexmap 2.2.5", "toml_datetime", "winnow 0.5.40", ] @@ -8689,7 +8681,7 @@ version = "0.20.7" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "70f427fce4d84c72b5b732388bf4a9f4531b53f74e2887e3ecb2481f68f66d81" dependencies = [ - "indexmap 2.2.3", + "indexmap 2.2.5", "toml_datetime", "winnow 0.5.40", ] @@ -8700,7 +8692,7 @@ version = "0.21.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6a8534fd7f78b5405e860340ad6575217ce99f38d4d5c8f2442cb5ecb50090e1" dependencies = [ - "indexmap 2.2.3", + "indexmap 2.2.5", "toml_datetime", "winnow 0.5.40", ] @@ -8711,11 +8703,11 @@ version = "0.22.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2c1b5fd4128cc8d3e0cb74d4ed9a9cc7c7284becd4df68f5f940e1ad123606f6" dependencies = [ - "indexmap 2.2.3", + "indexmap 2.2.5", "serde", "serde_spanned", "toml_datetime", - "winnow 0.6.2", + "winnow 0.6.5", ] [[package]] @@ -8825,7 +8817,7 @@ checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -8874,9 +8866,9 @@ dependencies = [ [[package]] name = "tracing-logfmt" -version = "0.3.3" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84bab42e40ace4e4ff19c92023ee1dbc1510db60976828fbbdc6994852c7d065" +checksum = "22b8e455f6caa5212a102ec530bf86b8dc5a4c536299bffd84b238fed9119be7" dependencies = [ "time", "tracing", @@ -9261,9 +9253,9 @@ checksum = "f3c4517f54858c779bbcbf228f4fca63d121bf85fbecb2dc578cdf4a39395690" [[package]] name = "walkdir" -version = "2.4.0" +version = "2.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d71d857dc86794ca4c280d616f7da00d2dbfd8cd788846559a6813e6aa4b54ee" +checksum = "29790946404f91d9c5d06f9874efddea1dc06c5efe94541a7d6863108e3a5e4b" dependencies = [ "same-file", "winapi-util", @@ -9292,9 +9284,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.91" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1e124130aee3fb58c5bdd6b639a0509486b0338acaaae0c84a5124b0f588b7f" +checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -9302,24 +9294,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.91" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c9e7e1900c352b609c8488ad12639a311045f40a35491fb69ba8c12f758af70b" +checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.41" +version = "0.4.42" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "877b9c3f61ceea0e56331985743b13f3d25c406a7098d45180fb5f09bc19ed97" +checksum = "76bc14366121efc8dbb487ab05bcc9d346b3b5ec0eaa76e46594cabbe51762c0" dependencies = [ "cfg-if", "js-sys", @@ -9329,9 +9321,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.91" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b30af9e2d358182b5c7449424f017eba305ed32a7010509ede96cdc4696c46ed" +checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -9339,22 +9331,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.91" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "642f325be6301eb8107a83d12a8ac6c1e1c54345a7ef1a9261962dfefda09e66" +checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.91" +version = "0.2.92" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4f186bd2dcf04330886ce82d6f33dd75a7bfcf69ecf5763b89fcde53b6ac9838" +checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" [[package]] name = "wasm-streams" @@ -9371,9 +9363,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.68" +version = "0.3.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96565907687f7aceb35bc5fc03770a8a0471d82e479f25832f54a0e3f4b28446" +checksum = "77afa9a11836342370f4817622a2f0f418b134426d91a82dfb48f532d2ec13ef" dependencies = [ "js-sys", "wasm-bindgen", @@ -9429,7 +9421,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e48a53791691ab099e5e2ad123536d0fff50652600abaf43bbf952894110d0be" dependencies = [ "windows-core", - "windows-targets 0.52.3", + "windows-targets 0.52.4", ] [[package]] @@ -9438,7 +9430,7 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "33ab640c8d7e35bf8ba19b884ba838ceb4fba93a4e8c65a9059d08afcfc683d9" dependencies = [ - "windows-targets 0.52.3", + "windows-targets 0.52.4", ] [[package]] @@ -9456,7 +9448,7 @@ version = "0.52.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" dependencies = [ - "windows-targets 0.52.3", + "windows-targets 0.52.4", ] [[package]] @@ -9476,17 +9468,17 @@ dependencies = [ [[package]] name = "windows-targets" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d380ba1dc7187569a8a9e91ed34b8ccfc33123bbacb8c0aed2d1ad7f3ef2dc5f" +checksum = "7dd37b7e5ab9018759f893a1952c9420d060016fc19a472b4bb20d1bdd694d1b" dependencies = [ - "windows_aarch64_gnullvm 0.52.3", - "windows_aarch64_msvc 0.52.3", - "windows_i686_gnu 0.52.3", - "windows_i686_msvc 0.52.3", - "windows_x86_64_gnu 0.52.3", - "windows_x86_64_gnullvm 0.52.3", - "windows_x86_64_msvc 0.52.3", + "windows_aarch64_gnullvm 0.52.4", + "windows_aarch64_msvc 0.52.4", + "windows_i686_gnu 0.52.4", + "windows_i686_msvc 0.52.4", + "windows_x86_64_gnu 0.52.4", + "windows_x86_64_gnullvm 0.52.4", + "windows_x86_64_msvc 0.52.4", ] [[package]] @@ -9497,9 +9489,9 @@ checksum = "2b38e32f0abccf9987a4e3079dfb67dcd799fb61361e53e2882c3cbaf0d905d8" [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68e5dcfb9413f53afd9c8f86e56a7b4d86d9a2fa26090ea2dc9e40fba56c6ec6" +checksum = "bcf46cf4c365c6f2d1cc93ce535f2c8b244591df96ceee75d8e83deb70a9cac9" [[package]] name = "windows_aarch64_msvc" @@ -9509,9 +9501,9 @@ checksum = "dc35310971f3b2dbbf3f0690a219f40e2d9afcf64f9ab7cc1be722937c26b4bc" [[package]] name = "windows_aarch64_msvc" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8dab469ebbc45798319e69eebf92308e541ce46760b49b18c6b3fe5e8965b30f" +checksum = "da9f259dd3bcf6990b55bffd094c4f7235817ba4ceebde8e6d11cd0c5633b675" [[package]] name = "windows_i686_gnu" @@ -9521,9 +9513,9 @@ checksum = "a75915e7def60c94dcef72200b9a8e58e5091744960da64ec734a6c6e9b3743e" [[package]] name = "windows_i686_gnu" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a4e9b6a7cac734a8b4138a4e1044eac3404d8326b6c0f939276560687a033fb" +checksum = "b474d8268f99e0995f25b9f095bc7434632601028cf86590aea5c8a5cb7801d3" [[package]] name = "windows_i686_msvc" @@ -9533,9 +9525,9 @@ checksum = "8f55c233f70c4b27f66c523580f78f1004e8b5a8b659e05a4eb49d4166cca406" [[package]] name = "windows_i686_msvc" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28b0ec9c422ca95ff34a78755cfa6ad4a51371da2a5ace67500cf7ca5f232c58" +checksum = "1515e9a29e5bed743cb4415a9ecf5dfca648ce85ee42e15873c3cd8610ff8e02" [[package]] name = "windows_x86_64_gnu" @@ -9545,9 +9537,9 @@ checksum = "53d40abd2583d23e4718fddf1ebec84dbff8381c07cae67ff7768bbf19c6718e" [[package]] name = "windows_x86_64_gnu" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "704131571ba93e89d7cd43482277d6632589b18ecf4468f591fbae0a8b101614" +checksum = "5eee091590e89cc02ad514ffe3ead9eb6b660aedca2183455434b93546371a03" [[package]] name = "windows_x86_64_gnullvm" @@ -9557,9 +9549,9 @@ checksum = "0b7b52767868a23d5bab768e390dc5f5c55825b6d30b86c844ff2dc7414044cc" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "42079295511643151e98d61c38c0acc444e52dd42ab456f7ccfd5152e8ecf21c" +checksum = "77ca79f2451b49fa9e2af39f0747fe999fcda4f5e241b2898624dca97a1f2177" [[package]] name = "windows_x86_64_msvc" @@ -9569,9 +9561,9 @@ checksum = "ed94fce61571a4006852b7389a063ab983c02eb1bb37b47f8272ce92d06d9538" [[package]] name = "windows_x86_64_msvc" -version = "0.52.3" +version = "0.52.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0770833d60a970638e989b3fa9fd2bb1aaadcf88963d1659fd7d9990196ed2d6" +checksum = "32b752e52a2da0ddfbdbcc6fceadfeede4c939ed16d13e648833a61dfb611ed8" [[package]] name = "winnow" @@ -9584,9 +9576,9 @@ dependencies = [ [[package]] name = "winnow" -version = "0.6.2" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7a4191c47f15cc3ec71fcb4913cb83d58def65dd3787610213c649283b5ce178" +checksum = "dffa400e67ed5a4dd237983829e66475f0a4a26938c4b04c21baede6262215b8" dependencies = [ "memchr", ] @@ -9685,7 +9677,7 @@ checksum = "9e6936f0cce458098a201c245a11bef556c6a0181129c7034d10d76d1ec3a2b8" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "synstructure", ] @@ -9706,7 +9698,7 @@ checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -9726,7 +9718,7 @@ checksum = "e6a647510471d372f2e6c2e6b7219e44d8c574d24fdc11c610a61455782f18c3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", "synstructure", ] @@ -9747,7 +9739,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] @@ -9770,7 +9762,7 @@ checksum = "7a4a1638a1934450809c2266a70362bfc96cd90550c073f5b8a55014d1010157" dependencies = [ "proc-macro2", "quote", - "syn 2.0.51", + "syn 2.0.52", ] [[package]] diff --git a/crates/primitives/src/revm/env.rs b/crates/primitives/src/revm/env.rs index f8e02a85ecdb..5fca556271a7 100644 --- a/crates/primitives/src/revm/env.rs +++ b/crates/primitives/src/revm/env.rs @@ -160,6 +160,8 @@ pub fn fill_tx_env_with_beacon_root_contract_call(env: &mut Env, parent_beacon_b // enveloped tx size. enveloped_tx: Some(Bytes::default()), }, + #[cfg(feature = "telos")] + first_new_address: None, }; // ensure the block gas limit is >= the tx diff --git a/crates/rpc/rpc/src/eth/revm_utils.rs b/crates/rpc/rpc/src/eth/revm_utils.rs index 445c67368901..cf1112a76434 100644 --- a/crates/rpc/rpc/src/eth/revm_utils.rs +++ b/crates/rpc/rpc/src/eth/revm_utils.rs @@ -375,6 +375,8 @@ pub(crate) fn create_txn_env( max_fee_per_blob_gas, #[cfg(feature = "optimism")] optimism: OptimismFields { enveloped_tx: Some(Bytes::new()), ..Default::default() }, + #[cfg(feature = "telos")] + first_new_address: None, }; Ok(env) From 7edd2fcb1e9d2c56e84915e47e522c016836d53d Mon Sep 17 00:00:00 2001 From: Amir Pasha Motamed Date: Thu, 25 Apr 2024 08:59:20 +0330 Subject: [PATCH 6/6] Activate telos feature on revm when needed --- Cargo.toml | 4 ++-- bin/reth/Cargo.toml | 10 ++++++++++ crates/node-api/Cargo.toml | 6 ++++++ crates/node-ethereum/Cargo.toml | 5 ++++- crates/payload/basic/Cargo.toml | 7 ++++++- crates/payload/builder/Cargo.toml | 4 ++++ crates/payload/ethereum/Cargo.toml | 3 +++ crates/payload/optimism/Cargo.toml | 3 +++ crates/primitives/Cargo.toml | 5 ++++- crates/revm/Cargo.toml | 3 +++ crates/rpc/rpc/Cargo.toml | 2 ++ crates/stages/Cargo.toml | 4 +++- crates/storage/provider/Cargo.toml | 4 +++- crates/transaction-pool/Cargo.toml | 3 +++ crates/trie/Cargo.toml | 3 +++ 15 files changed, 59 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 8f7a2836af78..36fc68ef63a3 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -171,8 +171,8 @@ reth-transaction-pool = { path = "crates/transaction-pool" } reth-trie = { path = "crates/trie" } # revm -revm = { git = "https://github.com/telosnetwork/telos-revm", branch = "telos-main", features = ["std", "secp256k1", "telos"], default-features = false } -revm-primitives = { git = "https://github.com/telosnetwork/telos-revm", branch = "telos-main", features = ["std", "telos"], default-features = false } +revm = { git = "https://github.com/telosnetwork/telos-revm", branch = "telos-main", features = ["std", "secp256k1"], default-features = false } +revm-primitives = { git = "https://github.com/telosnetwork/telos-revm", branch = "telos-main", features = ["std"], default-features = false } revm-inspectors = { git = "https://github.com/telosnetwork/telos-evm-inspectors", branch = "telos-main" } # eth diff --git a/bin/reth/Cargo.toml b/bin/reth/Cargo.toml index c1a3f0224796..8af689b895ca 100644 --- a/bin/reth/Cargo.toml +++ b/bin/reth/Cargo.toml @@ -186,6 +186,16 @@ telos = [ "reth-provider/telos", "reth-consensus-common/telos", "reth-stages/telos", + "reth-node-api/telos", + "reth-payload-builder/telos", + "reth-node-ethereum/telos", + "reth-basic-payload-builder/telos", + "reth-ethereum-payload-builder/telos", + "reth-optimism-payload-builder/telos", + "reth-revm/telos", + "reth-transaction-pool/telos", + "reth-trie/telos", + "reth-rpc-types-compat/telos" ] [[bin]] diff --git a/crates/node-api/Cargo.toml b/crates/node-api/Cargo.toml index 6b01dd8c0754..c9c84eaa3daf 100644 --- a/crates/node-api/Cargo.toml +++ b/crates/node-api/Cargo.toml @@ -20,3 +20,9 @@ revm.workspace = true # io serde.workspace = true + +[features] +telos = [ + "revm/telos", + "revm-primitives/telos", +] \ No newline at end of file diff --git a/crates/node-ethereum/Cargo.toml b/crates/node-ethereum/Cargo.toml index 47674bce8791..f2f864ed1c6f 100644 --- a/crates/node-ethereum/Cargo.toml +++ b/crates/node-ethereum/Cargo.toml @@ -35,4 +35,7 @@ reth-db.workspace = true [features] # This is a workaround for reth-cli crate to allow this as mandatory dependency without breaking the build even if unused. # This makes managing features and testing workspace easier because clippy always builds all members if --workspace is provided -optimism = [] \ No newline at end of file +optimism = [] +telos = [ + "revm/telos", +] \ No newline at end of file diff --git a/crates/payload/basic/Cargo.toml b/crates/payload/basic/Cargo.toml index 00ca2432cf99..e5d5ef9998fe 100644 --- a/crates/payload/basic/Cargo.toml +++ b/crates/payload/basic/Cargo.toml @@ -36,4 +36,9 @@ reth-metrics.workspace = true metrics.workspace = true # misc -tracing.workspace = true \ No newline at end of file +tracing.workspace = true + +[features] +telos = [ + "revm/telos", +] \ No newline at end of file diff --git a/crates/payload/builder/Cargo.toml b/crates/payload/builder/Cargo.toml index 8bb9372a8315..512b7d8f5d9d 100644 --- a/crates/payload/builder/Cargo.toml +++ b/crates/payload/builder/Cargo.toml @@ -56,3 +56,7 @@ optimism = [ "reth-interfaces/optimism", "reth-transaction-pool/optimism", ] +telos = [ + "revm/telos", + "revm-primitives/telos", +] diff --git a/crates/payload/ethereum/Cargo.toml b/crates/payload/ethereum/Cargo.toml index cb2d7baa0ab2..b8a1f5757147 100644 --- a/crates/payload/ethereum/Cargo.toml +++ b/crates/payload/ethereum/Cargo.toml @@ -30,3 +30,6 @@ tracing.workspace = true # This is a workaround for reth-cli crate to allow this as mandatory dependency without breaking the build even if unused. # This makes managing features and testing workspace easier because clippy always builds all members if --workspace is provided optimism = [] +telos = [ + "revm/telos", +] diff --git a/crates/payload/optimism/Cargo.toml b/crates/payload/optimism/Cargo.toml index 7ce5c044fc74..1d1afc0e0e6f 100644 --- a/crates/payload/optimism/Cargo.toml +++ b/crates/payload/optimism/Cargo.toml @@ -38,3 +38,6 @@ optimism = [ "reth-provider/optimism", "reth-payload-builder/optimism", ] +telos = [ + "revm/telos", +] diff --git a/crates/primitives/Cargo.toml b/crates/primitives/Cargo.toml index b4259afb52a5..9f7e00faf776 100644 --- a/crates/primitives/Cargo.toml +++ b/crates/primitives/Cargo.toml @@ -111,7 +111,10 @@ optimism = [ "reth-ethereum-forks/optimism", "revm/optimism", ] -telos = [] +telos = [ + "revm/telos", + "revm-primitives/telos", +] test-utils = ["dep:plain_hasher", "dep:hash-db", "dep:ethers-core"] [[bench]] diff --git a/crates/revm/Cargo.toml b/crates/revm/Cargo.toml index c38ab6d8c1d6..66d32f3b7f58 100644 --- a/crates/revm/Cargo.toml +++ b/crates/revm/Cargo.toml @@ -38,3 +38,6 @@ optimism = [ "reth-interfaces/optimism", ] js-tracer = ["revm-inspectors/js-tracer"] +telos = [ + "revm/telos", +] diff --git a/crates/rpc/rpc/Cargo.toml b/crates/rpc/rpc/Cargo.toml index 5ea927fa1919..5ad43c5d56b9 100644 --- a/crates/rpc/rpc/Cargo.toml +++ b/crates/rpc/rpc/Cargo.toml @@ -109,4 +109,6 @@ optimism = [ telos = [ "dep:reth-telos", "reth-rpc-types-compat/telos", + "revm/telos", + "revm-primitives/telos", ] \ No newline at end of file diff --git a/crates/stages/Cargo.toml b/crates/stages/Cargo.toml index 616e4dbe0a95..e7982c39d764 100644 --- a/crates/stages/Cargo.toml +++ b/crates/stages/Cargo.toml @@ -83,7 +83,9 @@ serde_json.workspace = true [features] test-utils = ["reth-interfaces/test-utils", "reth-db/test-utils"] -telos = [] +telos = [ + "revm/telos", +] [[bench]] name = "criterion" diff --git a/crates/storage/provider/Cargo.toml b/crates/storage/provider/Cargo.toml index 90bc249b3888..34accc0c16bd 100644 --- a/crates/storage/provider/Cargo.toml +++ b/crates/storage/provider/Cargo.toml @@ -62,4 +62,6 @@ rand.workspace = true [features] test-utils = ["alloy-rlp", "reth-db/test-utils"] optimism = ["reth-primitives/optimism", "reth-interfaces/optimism"] -telos = [] +telos = [ + "revm/telos", +] diff --git a/crates/transaction-pool/Cargo.toml b/crates/transaction-pool/Cargo.toml index faf8a541d670..f60d8dea4616 100644 --- a/crates/transaction-pool/Cargo.toml +++ b/crates/transaction-pool/Cargo.toml @@ -81,6 +81,9 @@ optimism = [ "reth-provider/optimism", "revm/optimism", ] +telos = [ + "revm/telos", +] [[bench]] name = "truncate" diff --git a/crates/trie/Cargo.toml b/crates/trie/Cargo.toml index 280189eada02..9011a37d0043 100644 --- a/crates/trie/Cargo.toml +++ b/crates/trie/Cargo.toml @@ -53,6 +53,9 @@ criterion.workspace = true [features] test-utils = ["triehash"] +telos = [ + "revm/telos", +] [[bench]] name = "prefix_set"