From e239bdf474d1e92701e0de2a8e19f7ef0700ef46 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 18:30:06 +0530 Subject: [PATCH 01/10] testing setup --- .gitignore | 2 + Cargo.toml | 1 + scripts/chiado_genesis_alloc.json | 3 +- src/lib.rs | 1 + src/testing/assert.rs | 18 + src/testing/case.rs | 42 +++ src/testing/cases/blockchain_test.rs | 270 +++++++++++++++ src/testing/cases/mod.rs | 3 + src/testing/mod.rs | 17 + src/testing/models.rs | 496 +++++++++++++++++++++++++++ src/testing/result.rs | 138 ++++++++ src/testing/suite.rs | 75 ++++ src/testing/tests/mod.rs | 1 + src/testing/tests/tests.rs | 109 ++++++ 14 files changed, 1175 insertions(+), 1 deletion(-) create mode 100644 src/testing/assert.rs create mode 100644 src/testing/case.rs create mode 100644 src/testing/cases/blockchain_test.rs create mode 100644 src/testing/cases/mod.rs create mode 100644 src/testing/mod.rs create mode 100644 src/testing/models.rs create mode 100644 src/testing/result.rs create mode 100644 src/testing/suite.rs create mode 100644 src/testing/tests/mod.rs create mode 100644 src/testing/tests/tests.rs diff --git a/.gitignore b/.gitignore index ea8c4bf..52b69b8 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ /target +ethereum-tests/ +fixtures/ \ No newline at end of file diff --git a/Cargo.toml b/Cargo.toml index dcc03fc..9b7a3af 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -21,6 +21,7 @@ reth-ethereum-consensus = { git = "https://github.com/paradigmxyz/reth", rev = " reth-chainspec = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } reth-chain-state = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } reth-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } +reth-cli = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } reth-cli-util = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } # reth-auto-seal-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } reth-prune-types = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } diff --git a/scripts/chiado_genesis_alloc.json b/scripts/chiado_genesis_alloc.json index 117bb7f..bec79e3 100644 --- a/scripts/chiado_genesis_alloc.json +++ b/scripts/chiado_genesis_alloc.json @@ -61,7 +61,8 @@ }, "registrar": "0x6000000000000000000000000000000000000000" }, - "eip1559collector": "0x1559000000000000000000000000000000000000" + "eip1559collector": "0x1559000000000000000000000000000000000000", + "depositContractAddress": "0xbabe2bed00000000000000000000000000000003" }, "baseFeePerGas": "0x3b9aca00", "difficulty": "0x01", diff --git a/src/lib.rs b/src/lib.rs index 3283bd3..5bbccc3 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -30,6 +30,7 @@ mod evm_config; pub mod execute; mod gnosis; mod payload_builder; +mod testing; #[derive(Debug, Clone, Default, PartialEq, Eq, clap::Args)] #[command(next_help_heading = "Gnosis")] diff --git a/src/testing/assert.rs b/src/testing/assert.rs new file mode 100644 index 0000000..4724ad3 --- /dev/null +++ b/src/testing/assert.rs @@ -0,0 +1,18 @@ +//! Various assertion helpers. + +use crate::testing::Error; +use std::fmt::Debug; + +/// A helper like `assert_eq!` that instead returns `Err(Error::Assertion)` on failure. +pub fn assert_equal(left: T, right: T, msg: &str) -> Result<(), Error> +where + T: PartialEq + Debug, +{ + if left == right { + Ok(()) + } else { + Err(Error::Assertion(format!( + "{msg}\n left `{left:?}`,\n right `{right:?}`" + ))) + } +} diff --git a/src/testing/case.rs b/src/testing/case.rs new file mode 100644 index 0000000..0535b47 --- /dev/null +++ b/src/testing/case.rs @@ -0,0 +1,42 @@ +//! Test case definitions + +use crate::testing::result::{CaseResult, Error}; +use std::{ + fmt::Debug, + path::{Path, PathBuf}, +}; + +/// A single test case, capable of loading a JSON description of itself and running it. +/// +/// See for test specs. +pub trait Case: Debug + Sync + Sized { + /// A description of the test. + fn description(&self) -> String { + "no description".to_string() + } + + /// Load the test from the given file path. + /// + /// The file can be assumed to be a valid EF test case as described on . + fn load(path: &Path) -> Result; + + /// Run the test. + fn run(&self) -> Result<(), Error>; +} + +/// A container for multiple test cases. +#[derive(Debug)] +pub struct Cases { + /// The contained test cases and the path to each test. + pub test_cases: Vec<(PathBuf, T)>, +} + +impl Cases { + /// Run the contained test cases. + pub fn run(&self) -> Vec { + self.test_cases + .iter() + .map(|(path, case)| CaseResult::new(path, case, case.run())) + .collect() + } +} diff --git a/src/testing/cases/blockchain_test.rs b/src/testing/cases/blockchain_test.rs new file mode 100644 index 0000000..3ab8343 --- /dev/null +++ b/src/testing/cases/blockchain_test.rs @@ -0,0 +1,270 @@ +//! Test runners for `BlockchainTests` in + +use crate::{execute::GnosisExecutorProvider, testing::{ + models::{BlockchainTest, ForkSpec}, + Case, Error, Suite, +}}; +use alloy_rlp::Decodable; +use rayon::iter::{ParallelBridge, ParallelIterator}; +use reth_chainspec::ChainSpec; +use reth_cli::chainspec::parse_genesis; +use reth_primitives::{BlockBody, SealedBlock, StaticFileSegment}; +use reth_provider::{ + providers::StaticFileWriter, test_utils::create_test_provider_factory_with_chain_spec, BlockReader, DatabaseProviderFactory, HashingWriter, StaticFileProviderFactory, TransactionVariant +}; +use reth_stages::{stages::ExecutionStage, ExecInput, Stage}; +use revm_primitives::Address; +use std::{collections::BTreeMap, fs, path::{Path, PathBuf}, sync::Arc}; + +/// A handler for the blockchain test suite. +#[derive(Debug)] +pub struct BlockchainTests { + suite: String, +} + +impl BlockchainTests { + /// Create a new handler for a subset of the blockchain test suite. + pub const fn new(suite: String) -> Self { + Self { suite } + } +} + +impl Suite for BlockchainTests { + type Case = BlockchainTestCase; + + fn suite_name(&self) -> String { + self.suite.clone() + } +} + +/// An Ethereum blockchain test. +#[derive(Debug, PartialEq, Eq)] +pub struct BlockchainTestCase { + tests: BTreeMap, + skip: bool, +} + +impl Case for BlockchainTestCase { + fn load(path: &Path) -> Result { + Ok(Self { + tests: { + let s = fs::read_to_string(path).map_err(|error| Error::Io { + path: path.into(), + error, + })?; + let test = serde_json::from_str(&s).map_err(|error| Error::CouldNotDeserialize { + path: path.into(), + error, + })?; + test + }, + skip: should_skip(path), + }) + } + + /// Runs the test cases for the Ethereum Forks test suite. + /// + /// # Errors + /// Returns an error if the test is flagged for skipping or encounters issues during execution. + fn run(&self) -> Result<(), Error> { + // If the test is marked for skipping, return a Skipped error immediately. + if self.skip { + return Err(Error::Skipped); + } + + let chainspec_path = PathBuf::from(env!("CARGO_MANIFEST_DIR")) + .join("scripts") + .join("chiado_genesis_alloc.json"); + let original_chain_spec: ChainSpec = parse_genesis(chainspec_path.to_str().unwrap()).unwrap().into(); + // let chain_spec: Arc = Arc::new(chain_spec); + + // Iterate through test cases, filtering by the network type to exclude specific forks. + self.tests + .values() + .filter(|case| { + !matches!( + case.network, + ForkSpec::ByzantiumToConstantinopleAt5 + | ForkSpec::Frontier + | ForkSpec::Homestead + | ForkSpec::Byzantium + | ForkSpec::Istanbul + | ForkSpec::Berlin + | ForkSpec::London + | ForkSpec::Constantinople + | ForkSpec::ConstantinopleFix + | ForkSpec::MergeEOF + | ForkSpec::MergeMeterInitCode + | ForkSpec::MergePush0 + | ForkSpec::Unknown + | ForkSpec::Berlin + | ForkSpec::London + | ForkSpec::Istanbul + ) + }) + .par_bridge() + .try_for_each(|case| { + // Create a new test database and initialize a provider for the test case. + let mut chain_spec: ChainSpec = case.network.clone().into(); + chain_spec.genesis.config.extra_fields.insert(String::from("eip1559collector"), original_chain_spec.genesis.config.extra_fields.get("eip1559collector").unwrap().clone()); + chain_spec.genesis.config.extra_fields.insert(String::from("blockRewardsContract"), original_chain_spec.genesis.config.extra_fields.get("blockRewardsContract").unwrap().clone()); + chain_spec.deposit_contract = original_chain_spec.deposit_contract; + let chain_spec: Arc = Arc::new(chain_spec); + let provider = create_test_provider_factory_with_chain_spec(chain_spec.clone()); + + let provider = provider + .database_provider_rw() + .unwrap(); + + // provider. + + // Insert initial test state into the provider. + provider.insert_historical_block( + SealedBlock::new( + case.genesis_block_header.clone().into(), + BlockBody::default(), + ) + .try_seal_with_senders() + .unwrap(), + )?; + case.pre.write_to_db(provider.tx_ref())?; + + // Initialize receipts static file with genesis + { + let static_file_provider = provider.static_file_provider(); + let mut receipts_writer = static_file_provider + .latest_writer(StaticFileSegment::Receipts) + .unwrap(); + receipts_writer.increment_block(0).unwrap(); + receipts_writer.commit_without_sync_all().unwrap(); + } + + // Decode and insert blocks, creating a chain of blocks for the test case. + let last_block = case.blocks.iter().try_fold(None, |_, block| { + let decoded = SealedBlock::decode(&mut block.rlp.as_ref())?; + dbg!("printing block during insertion: {:?}", decoded.clone().try_seal_with_senders().unwrap()); + provider.insert_historical_block( + decoded.clone().try_seal_with_senders().unwrap(), + )?; + Ok::, Error>(Some(decoded)) + })?; + provider + .static_file_provider() + .latest_writer(StaticFileSegment::Headers) + .unwrap() + .commit_without_sync_all() + .unwrap(); + let collector_address = chain_spec + .genesis() + .config + .extra_fields + .get("eip1559collector") + .ok_or(Error::Custom("no eip1559collector field".to_string()))?; + let collector_address: Address = serde_json::from_value(collector_address.clone()).unwrap(); + let gnosis_executor_provider = GnosisExecutorProvider::gnosis(chain_spec.clone()); + + + let block = provider.sealed_block_with_senders(1.into(), TransactionVariant::NoHash); + // Execute the execution stage using the EVM processor factory for the test case + // network. + let result = ExecutionStage::new_with_executor( + gnosis_executor_provider, + ) + .execute( + &provider, + ExecInput { + target: last_block.as_ref().map(|b| b.number), + checkpoint: None, + }, + ); + if let Err(e) = result { + return Err(Error::Custom("error in execution stage".to_string())); + } + + // Validate the post-state for the test case. + match (&case.post_state, &case.post_state_hash) { + (Some(state), None) => { + // Validate accounts in the state against the provider's database. + for (&address, account) in state { + account.assert_db(address, provider.tx_ref())?; + } + } + (None, Some(expected_state_root)) => { + // Insert state hashes into the provider based on the expected state root. + let last_block = last_block.unwrap_or_default(); + provider.insert_hashes( + 0..=last_block.number, + last_block.hash(), + *expected_state_root, + )?; + } + _ => { + dbg!("step 10/n"); + return Err(Error::MissingPostState); + }, + } + + + // Drop the provider without committing to the database. + drop(provider); + Ok(()) + })?; + + Ok(()) + } +} + +/// Returns whether the test at the given path should be skipped. +/// +/// Some tests are edge cases that cannot happen on mainnet, while others are skipped for +/// convenience (e.g. they take a long time to run) or are temporarily disabled. +/// +/// The reason should be documented in a comment above the file name(s). +pub fn should_skip(path: &Path) -> bool { + let path_str = path.to_str().expect("Path is not valid UTF-8"); + let name = path.file_name().unwrap().to_str().unwrap(); + false && matches!( + name, + // funky test with `bigint 0x00` value in json :) not possible to happen on mainnet and require + // custom json parser. https://github.com/ethereum/tests/issues/971 + | "ValueOverflow.json" + | "ValueOverflowParis.json" + + // txbyte is of type 02 and we don't parse tx bytes for this test to fail. + | "typeTwoBerlin.json" + + // Test checks if nonce overflows. We are handling this correctly but we are not parsing + // exception in testsuite There are more nonce overflow tests that are in internal + // call/create, and those tests are passing and are enabled. + | "CreateTransactionHighNonce.json" + + // Test check if gas price overflows, we handle this correctly but does not match tests specific + // exception. + | "HighGasPrice.json" + | "HighGasPriceParis.json" + + // Skip test where basefee/accesslist/difficulty is present but it shouldn't be supported in + // London/Berlin/TheMerge. https://github.com/ethereum/tests/blob/5b7e1ab3ffaf026d99d20b17bb30f533a2c80c8b/GeneralStateTests/stExample/eip1559.json#L130 + // It is expected to not execute these tests. + | "accessListExample.json" + | "basefeeExample.json" + | "eip1559.json" + | "mergeTest.json" + + // These tests are passing, but they take a lot of time to execute so we are going to skip them. + | "loopExp.json" + | "Call50000_sha256.json" + | "static_Call50000_sha256.json" + | "loopMul.json" + | "CALLBlake2f_MaxRounds.json" + | "shiftCombinations.json" + ) + // Ignore outdated EOF tests that haven't been updated for Cancun yet. + || path_contains(path_str, &["EIPTests", "stEOF"]) +} + +/// `str::contains` but for a path. Takes into account the OS path separator (`/` or `\`). +fn path_contains(path_str: &str, rhs: &[&str]) -> bool { + let rhs = rhs.join(std::path::MAIN_SEPARATOR_STR); + path_str.contains(&rhs) +} diff --git a/src/testing/cases/mod.rs b/src/testing/cases/mod.rs new file mode 100644 index 0000000..cfde4ac --- /dev/null +++ b/src/testing/cases/mod.rs @@ -0,0 +1,3 @@ +//! Specific test case handler implementations. + +pub mod blockchain_test; diff --git a/src/testing/mod.rs b/src/testing/mod.rs new file mode 100644 index 0000000..de6bd41 --- /dev/null +++ b/src/testing/mod.rs @@ -0,0 +1,17 @@ +#![allow(dead_code)] +#![cfg(test)] +#[cfg(feature = "testing")] + +pub mod case; +pub mod result; +pub mod suite; + +pub mod assert; +pub mod cases; +pub mod models; + +pub use case::Case; +pub use result::Error; +pub use suite::Suite; + +pub mod tests; diff --git a/src/testing/models.rs b/src/testing/models.rs new file mode 100644 index 0000000..87dc4aa --- /dev/null +++ b/src/testing/models.rs @@ -0,0 +1,496 @@ +//! Shared models for + +use crate::testing::{assert::assert_equal, Error}; +use alloy_consensus::Header as RethHeader; +use alloy_eips::eip4895::Withdrawals; +use alloy_primitives::{keccak256, Address, Bloom, Bytes, B256, B64, U256}; +use reth_chainspec::{ChainSpec, ChainSpecBuilder}; +use reth_db::tables; +use reth_db_api::{ + cursor::DbDupCursorRO, + transaction::{DbTx, DbTxMut}, +}; +use reth_primitives::{Account as RethAccount, Bytecode, SealedHeader, StorageEntry}; +use serde::Deserialize; +use std::{collections::BTreeMap, ops::Deref}; + +/// The definition of a blockchain test. +#[derive(Debug, PartialEq, Eq, Deserialize)] +#[serde(rename_all = "camelCase")] +pub struct BlockchainTest { + /// Genesis block header. + pub genesis_block_header: Header, + /// RLP encoded genesis block. + #[serde(rename = "genesisRLP")] + pub genesis_rlp: Option, + /// Block data. + pub blocks: Vec, + /// The expected post state. + pub post_state: Option>, + /// The expected post state merkle root. + pub post_state_hash: Option, + /// The test pre-state. + pub pre: State, + /// Hash of the best block. + pub lastblockhash: B256, + /// Network spec. + pub network: ForkSpec, + #[serde(default)] + /// Engine spec. + pub seal_engine: SealEngine, +} + +/// A block header in an Ethereum blockchain test. +#[derive(Debug, PartialEq, Eq, Clone, Deserialize, Default)] +#[serde(rename_all = "camelCase")] +pub struct Header { + /// Bloom filter. + pub bloom: Bloom, + /// Coinbase. + pub coinbase: Address, + /// Difficulty. + pub difficulty: U256, + /// Extra data. + pub extra_data: Bytes, + /// Gas limit. + pub gas_limit: U256, + /// Gas used. + pub gas_used: U256, + /// Block Hash. + pub hash: B256, + /// Mix hash. + pub mix_hash: B256, + /// Seal nonce. + pub nonce: B64, + /// Block number. + pub number: U256, + /// Parent hash. + pub parent_hash: B256, + /// Receipt trie. + pub receipt_trie: B256, + /// State root. + pub state_root: B256, + /// Timestamp. + pub timestamp: U256, + /// Transactions trie. + pub transactions_trie: B256, + /// Uncle hash. + pub uncle_hash: B256, + /// Base fee per gas. + pub base_fee_per_gas: Option, + /// Withdrawals root. + pub withdrawals_root: Option, + /// Blob gas used. + pub blob_gas_used: Option, + /// Excess blob gas. + pub excess_blob_gas: Option, + /// Parent beacon block root. + pub parent_beacon_block_root: Option, + /// Requests root. + pub requests_root: Option, +} + +impl From
for SealedHeader { + fn from(value: Header) -> Self { + let header = RethHeader { + base_fee_per_gas: value.base_fee_per_gas.map(|v| v.to::()), + beneficiary: value.coinbase, + difficulty: value.difficulty, + extra_data: value.extra_data, + gas_limit: value.gas_limit.to::(), + gas_used: value.gas_used.to::(), + mix_hash: value.mix_hash, + nonce: u64::from_be_bytes(value.nonce.0).into(), + number: value.number.to::(), + timestamp: value.timestamp.to::(), + transactions_root: value.transactions_trie, + receipts_root: value.receipt_trie, + ommers_hash: value.uncle_hash, + state_root: value.state_root, + parent_hash: value.parent_hash, + logs_bloom: value.bloom, + withdrawals_root: value.withdrawals_root, + blob_gas_used: value.blob_gas_used.map(|v| v.to::()), + excess_blob_gas: value.excess_blob_gas.map(|v| v.to::()), + parent_beacon_block_root: value.parent_beacon_block_root, + requests_hash: value.requests_root, + }; + Self::new(header, value.hash) + } +} + +/// A block in an Ethereum blockchain test. +#[derive(Debug, PartialEq, Eq, Deserialize, Default)] +#[serde(rename_all = "camelCase")] +pub struct Block { + /// Block header. + pub block_header: Option
, + /// RLP encoded block bytes + pub rlp: Bytes, + /// Transactions + pub transactions: Option>, + /// Uncle/ommer headers + pub uncle_headers: Option>, + /// Transaction Sequence + pub transaction_sequence: Option>, + /// Withdrawals + pub withdrawals: Option, +} + +/// Transaction sequence in block +#[derive(Debug, PartialEq, Eq, Deserialize, Default)] +#[serde(deny_unknown_fields)] +#[serde(rename_all = "camelCase")] +pub struct TransactionSequence { + exception: String, + raw_bytes: Bytes, + valid: String, +} + +/// Ethereum blockchain test data state. +#[derive(Clone, Debug, Eq, PartialEq, Deserialize, Default)] +pub struct State(BTreeMap); + +impl State { + /// Write the state to the database. + pub fn write_to_db(&self, tx: &impl DbTxMut) -> Result<(), Error> { + for (&address, account) in &self.0 { + let hashed_address = keccak256(address); + let has_code = !account.code.is_empty(); + let code_hash = has_code.then(|| keccak256(&account.code)); + let reth_account = RethAccount { + balance: account.balance, + nonce: account.nonce.to::(), + bytecode_hash: code_hash, + }; + tx.put::(address, reth_account)?; + tx.put::(hashed_address, reth_account)?; + if let Some(code_hash) = code_hash { + tx.put::(code_hash, Bytecode::new_raw(account.code.clone()))?; + } + account + .storage + .iter() + .filter(|(_, v)| !v.is_zero()) + .try_for_each(|(k, v)| { + let storage_key = B256::from_slice(&k.to_be_bytes::<32>()); + tx.put::( + address, + StorageEntry { + key: storage_key, + value: *v, + }, + )?; + tx.put::( + hashed_address, + StorageEntry { + key: keccak256(storage_key), + value: *v, + }, + ) + })?; + } + + Ok(()) + } +} + +impl Deref for State { + type Target = BTreeMap; + + fn deref(&self) -> &Self::Target { + &self.0 + } +} + +/// An account. +#[derive(Debug, PartialEq, Eq, Deserialize, Clone, Default)] +#[serde(deny_unknown_fields)] +pub struct Account { + /// Balance. + pub balance: U256, + /// Code. + pub code: Bytes, + /// Nonce. + pub nonce: U256, + /// Storage. + pub storage: BTreeMap, +} + +impl Account { + /// Check that the account matches what is in the database. + /// + /// In case of a mismatch, `Err(Error::Assertion)` is returned. + pub fn assert_db(&self, address: Address, tx: &impl DbTx) -> Result<(), Error> { + let account = tx + .get::(address)? + .ok_or_else(|| { + Error::Assertion(format!( + "Expected account ({address}) is missing from DB: {self:?}" + )) + })?; + + dbg!("Account for {}: {:?}", address, account); + + assert_equal(self.balance, account.balance, "Balance does not match")?; + assert_equal(self.nonce.to(), account.nonce, "Nonce does not match")?; + + if let Some(bytecode_hash) = account.bytecode_hash { + assert_equal( + keccak256(&self.code), + bytecode_hash, + "Bytecode does not match", + )?; + } else { + assert_equal( + self.code.is_empty(), + true, + "Expected empty bytecode, got bytecode in db.", + )?; + } + + let mut storage_cursor = tx.cursor_dup_read::()?; + dbg!("self.storage: {:?}", self.storage.clone()); + // dbg!("printing all storage entries"); + // let mut all = storage_cursor.walk(None).unwrap(); + // while let Ok(entry) = all.next().unwrap() { + // dbg!("Storage entries: {:?}", entry); + // } + for (slot, value) in &self.storage { + if let Some(entry) = + storage_cursor.seek_by_key_subkey(address, B256::new(slot.to_be_bytes()))? + { + dbg!("Storage entry: {:?}", entry); + if U256::from_be_bytes(entry.key.0) == *slot { + assert_equal( + *value, + entry.value, + &format!("Storage for slot {slot:?} does not match"), + )?; + } else { + return Err(Error::Assertion(format!( + "Slot {slot:?} is missing from the database. Expected {value:?}" + ))); + } + } else { + return Err(Error::Assertion(format!( + "Slot {slot:?} is missing from the database. Expected {value:?}" + ))); + } + } + + Ok(()) + } +} + +/// Fork specification. +#[derive(Debug, PartialEq, Eq, PartialOrd, Hash, Ord, Clone, Deserialize)] +pub enum ForkSpec { + /// Frontier + Frontier, + /// Frontier to Homestead + FrontierToHomesteadAt5, + /// Homestead + Homestead, + /// Homestead to Tangerine + HomesteadToDaoAt5, + /// Homestead to Tangerine + HomesteadToEIP150At5, + /// Tangerine + EIP150, + /// Spurious Dragon + EIP158, // EIP-161: State trie clearing + /// Spurious Dragon to Byzantium + EIP158ToByzantiumAt5, + /// Byzantium + Byzantium, + /// Byzantium to Constantinople + ByzantiumToConstantinopleAt5, // SKIPPED + /// Byzantium to Constantinople + ByzantiumToConstantinopleFixAt5, + /// Constantinople + Constantinople, // SKIPPED + /// Constantinople fix + ConstantinopleFix, + /// Istanbul + Istanbul, + /// Berlin + Berlin, + /// Berlin to London + BerlinToLondonAt5, + /// London + London, + /// Paris aka The Merge + Merge, + /// Shanghai + Shanghai, + /// Merge EOF test + #[serde(alias = "Merge+3540+3670")] + MergeEOF, + /// After Merge Init Code test + #[serde(alias = "Merge+3860")] + MergeMeterInitCode, + /// After Merge plus new PUSH0 opcode + #[serde(alias = "Merge+3855")] + MergePush0, + /// Cancun + Cancun, + /// Fork Spec which is unknown to us + #[serde(other)] + Unknown, +} + +impl From for ChainSpec { + fn from(fork_spec: ForkSpec) -> Self { + let spec_builder = ChainSpecBuilder::mainnet(); + + match fork_spec { + ForkSpec::Frontier => spec_builder.frontier_activated(), + ForkSpec::Homestead | ForkSpec::FrontierToHomesteadAt5 => { + spec_builder.homestead_activated() + } + ForkSpec::EIP150 | ForkSpec::HomesteadToDaoAt5 | ForkSpec::HomesteadToEIP150At5 => { + spec_builder.tangerine_whistle_activated() + } + ForkSpec::EIP158 => spec_builder.spurious_dragon_activated(), + ForkSpec::Byzantium + | ForkSpec::EIP158ToByzantiumAt5 + | ForkSpec::ConstantinopleFix + | ForkSpec::ByzantiumToConstantinopleFixAt5 => spec_builder.byzantium_activated(), + ForkSpec::Istanbul => spec_builder.istanbul_activated(), + ForkSpec::Berlin => spec_builder.berlin_activated(), + ForkSpec::London | ForkSpec::BerlinToLondonAt5 => spec_builder.london_activated(), + ForkSpec::Merge + | ForkSpec::MergeEOF + | ForkSpec::MergeMeterInitCode + | ForkSpec::MergePush0 => spec_builder.paris_activated(), + ForkSpec::Shanghai => spec_builder.shanghai_activated(), + ForkSpec::Cancun => spec_builder.cancun_activated(), + ForkSpec::ByzantiumToConstantinopleAt5 | ForkSpec::Constantinople => { + panic!("Overridden with PETERSBURG") + } + ForkSpec::Unknown => { + panic!("Unknown fork"); + } + } + .build() + } +} + +/// Possible seal engines. +#[derive(Debug, PartialEq, Eq, Default, Deserialize)] +pub enum SealEngine { + /// No consensus checks. + #[default] + NoProof, +} + +/// Ethereum blockchain test transaction data. +#[derive(Debug, PartialEq, Eq, Deserialize)] +#[serde(rename_all = "camelCase")] +pub struct Transaction { + /// Transaction type + #[serde(rename = "type")] + pub transaction_type: Option, + /// Data. + pub data: Bytes, + /// Gas limit. + pub gas_limit: U256, + /// Gas price. + pub gas_price: Option, + /// Nonce. + pub nonce: U256, + /// Signature r part. + pub r: U256, + /// Signature s part. + pub s: U256, + /// Parity bit. + pub v: U256, + /// Transaction value. + pub value: U256, + /// Chain ID. + pub chain_id: Option, + /// Access list. + pub access_list: Option, + /// Max fee per gas. + pub max_fee_per_gas: Option, + /// Max priority fee per gas + pub max_priority_fee_per_gas: Option, + /// Transaction hash. + pub hash: Option, +} + +/// Access list item +#[derive(Debug, PartialEq, Eq, Deserialize, Clone)] +#[serde(rename_all = "camelCase")] +pub struct AccessListItem { + /// Account address + pub address: Address, + /// Storage key. + pub storage_keys: Vec, +} + +/// Access list. +pub type AccessList = Vec; + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn header_deserialize() { + let test = r#"{ + "baseFeePerGas" : "0x0a", + "bloom" : "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "coinbase" : "0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "difficulty" : "0x020000", + "extraData" : "0x00", + "gasLimit" : "0x10000000000000", + "gasUsed" : "0x10000000000000", + "hash" : "0x7ebfee2a2c785fef181b8ffd92d4a48a0660ec000f465f309757e3f092d13882", + "mixHash" : "0x0000000000000000000000000000000000000000000000000000000000000000", + "nonce" : "0x0000000000000000", + "number" : "0x01", + "parentHash" : "0xa8f2eb2ea9dccbf725801eef5a31ce59bada431e888dfd5501677cc4365dc3be", + "receiptTrie" : "0xbdd943f5c62ae0299324244a0f65524337ada9817e18e1764631cc1424f3a293", + "stateRoot" : "0xc9c6306ee3e5acbaabe8e2fa28a10c12e27bad1d1aacc271665149f70519f8b0", + "timestamp" : "0x03e8", + "transactionsTrie" : "0xf5893b055ca05e4f14d1792745586a1376e218180bd56bd96b2b024e1dc78300", + "uncleHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347" + }"#; + let res = serde_json::from_str::
(test); + assert!( + res.is_ok(), + "Failed to deserialize Header with error: {res:?}" + ); + } + + #[test] + fn transaction_deserialize() { + let test = r#"[ + { + "accessList" : [ + ], + "chainId" : "0x01", + "data" : "0x693c61390000000000000000000000000000000000000000000000000000000000000000", + "gasLimit" : "0x10000000000000", + "maxFeePerGas" : "0x07d0", + "maxPriorityFeePerGas" : "0x00", + "nonce" : "0x01", + "r" : "0x5fecc3972a35c9e341b41b0c269d9a7325e13269fb01c2f64cbce1046b3441c8", + "s" : "0x7d4d0eda0e4ebd53c5d0b6fc35c600b317f8fa873b3963ab623ec9cec7d969bd", + "sender" : "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b", + "to" : "0xcccccccccccccccccccccccccccccccccccccccc", + "type" : "0x02", + "v" : "0x01", + "value" : "0x00" + } + ]"#; + + let res = serde_json::from_str::>(test); + assert!( + res.is_ok(), + "Failed to deserialize transaction with error: {res:?}" + ); + } +} diff --git a/src/testing/result.rs b/src/testing/result.rs new file mode 100644 index 0000000..7d08007 --- /dev/null +++ b/src/testing/result.rs @@ -0,0 +1,138 @@ +//! Test results and errors + +use crate::testing::Case; +use reth_db::DatabaseError; +use reth_provider::ProviderError; +use std::path::{Path, PathBuf}; +use thiserror::Error; + +/// Test errors +/// +/// # Note +/// +/// `Error::Skipped` should not be treated as a test failure. +#[derive(Debug, Error)] +#[non_exhaustive] +pub enum Error { + /// The test was skipped + #[error("test was skipped")] + Skipped, + /// No post state found in test + #[error("no post state found for validation")] + MissingPostState, + /// An IO error occurred + #[error("an error occurred interacting with the file system at {path}: {error}")] + Io { + /// The path to the file or directory + path: PathBuf, + /// The specific error + #[source] + error: std::io::Error, + }, + /// A deserialization error occurred + #[error("an error occurred deserializing the test at {path}: {error}")] + CouldNotDeserialize { + /// The path to the file we wanted to deserialize + path: PathBuf, + /// The specific error + #[source] + error: serde_json::Error, + }, + /// A database error occurred. + #[error(transparent)] + Database(#[from] DatabaseError), + /// A test assertion failed. + #[error("test failed: {0}")] + Assertion(String), + /// An error internally in reth occurred. + #[error("test failed: {0}")] + Provider(#[from] ProviderError), + /// An error occurred while decoding RLP. + #[error("an error occurred deserializing RLP: {0}")] + RlpDecode(#[from] alloy_rlp::Error), + /// Custom error message + #[error("{0}")] + Custom(String), +} + +/// The result of running a test. +#[derive(Debug)] +pub struct CaseResult { + /// A description of the test. + pub desc: String, + /// The full path to the test. + pub path: PathBuf, + /// The result of the test. + pub result: Result<(), Error>, +} + +impl CaseResult { + /// Create a new test result. + pub fn new(path: &Path, case: &impl Case, result: Result<(), Error>) -> Self { + Self { + desc: case.description(), + path: path.into(), + result, + } + } +} + +/// Assert that all the given tests passed and print the results to stdout. +pub(crate) fn assert_tests_pass(suite_name: &str, path: &Path, results: &[CaseResult]) { + let (passed, failed, skipped) = categorize_results(results); + + print_results(suite_name, path, &passed, &failed, &skipped); + + assert!(failed.is_empty(), "Some tests failed (see above)"); +} + +/// Categorize test results into `(passed, failed, skipped)`. +pub(crate) fn categorize_results( + results: &[CaseResult], +) -> (Vec<&CaseResult>, Vec<&CaseResult>, Vec<&CaseResult>) { + let mut passed = Vec::new(); + let mut failed = Vec::new(); + let mut skipped = Vec::new(); + + for case in results { + match case.result.as_ref().err() { + Some(Error::Skipped) => skipped.push(case), + Some(_) => failed.push(case), + None => passed.push(case), + } + } + + (passed, failed, skipped) +} + +/// Display the given test results to stdout. +pub(crate) fn print_results( + suite_name: &str, + path: &Path, + passed: &[&CaseResult], + failed: &[&CaseResult], + skipped: &[&CaseResult], +) { + println!("Suite: {suite_name} (at {})", path.display()); + println!( + "Ran {} tests ({} passed, {} failed, {} skipped)", + passed.len() + failed.len() + skipped.len(), + passed.len(), + failed.len(), + skipped.len() + ); + + for case in skipped { + println!("[S] Case {} skipped", case.path.display()); + } + + for case in failed { + let error = case.result.as_ref().unwrap_err(); + println!( + "[!] Case {} failed (description: {}): {}", + case.path.display(), + case.desc, + error + ); + } +} diff --git a/src/testing/suite.rs b/src/testing/suite.rs new file mode 100644 index 0000000..9b6076b --- /dev/null +++ b/src/testing/suite.rs @@ -0,0 +1,75 @@ +//! Abstractions for groups of tests. + +use crate::testing::{ + case::{Case, Cases}, + result::assert_tests_pass, +}; +use std::path::{Path, PathBuf}; +use walkdir::{DirEntry, WalkDir}; + +/// A collection of tests. +pub trait Suite { + /// The type of test cases in this suite. + type Case: Case; + + /// The name of the test suite used to locate the individual test cases. + /// + /// # Example + /// + /// - `GeneralStateTests` + /// - `BlockchainTests/InvalidBlocks` + /// - `BlockchainTests/TransitionTests` + fn suite_name(&self) -> String; + + /// Load an run each contained test case. + /// + /// # Note + /// + /// This recursively finds every test description in the resulting path. + fn run(&self) { + // Build the path to the test suite directory + // let suite_path = PathBuf::from(env!("CARGO_MANIFEST_DIR")) + // .join("fixtures") + // .join(self.suite_name()); + dbg!("suit path", self.suite_name()); + let suite_path = match self.suite_name().starts_with("blockchain_tests") { + true => PathBuf::from(env!("CARGO_MANIFEST_DIR")) + .join("fixtures") + .join(self.suite_name()), + false => PathBuf::from(env!("CARGO_MANIFEST_DIR")) + .join("ethereum-tests") + .join(self.suite_name()), + }; + + // Verify that the path exists + assert!( + suite_path.exists(), + "Test suite path does not exist: {suite_path:?}" + ); + + // Find all files with the ".json" extension in the test suite directory + let test_cases = find_all_files_with_extension(&suite_path, ".json") + .into_iter() + .map(|test_case_path| { + let case = Self::Case::load(&test_case_path).expect("test case should load"); + (test_case_path, case) + }) + .collect(); + + // Run the test cases and collect the results + let results = Cases { test_cases }.run(); + + // Assert that all tests in the suite pass + assert_tests_pass(&self.suite_name(), &suite_path, &results); + } +} + +/// Recursively find all files with a given extension. +fn find_all_files_with_extension(path: &Path, extension: &str) -> Vec { + WalkDir::new(path) + .into_iter() + .filter_map(Result::ok) + .filter(|e| e.file_name().to_string_lossy().ends_with(extension)) + .map(DirEntry::into_path) + .collect() +} diff --git a/src/testing/tests/mod.rs b/src/testing/tests/mod.rs new file mode 100644 index 0000000..14f0038 --- /dev/null +++ b/src/testing/tests/mod.rs @@ -0,0 +1 @@ +mod tests; diff --git a/src/testing/tests/tests.rs b/src/testing/tests/tests.rs new file mode 100644 index 0000000..d3cbf03 --- /dev/null +++ b/src/testing/tests/tests.rs @@ -0,0 +1,109 @@ +#![allow(missing_docs)] +#![cfg(feature = "testing")] +#![cfg(test)] + +macro_rules! general_state_test { + ($test_name:ident, $fork_or_testname:ident $(, $test:ident, $testname:ident)?) => { + #[test] + fn $test_name() { + // if test and testname is empty, then return BlockchainTests::new(format!("GeneralStateTests/{}", stringify!($dir))).run(); + if stringify!($($test)?).is_empty() && stringify!($($testname)?).is_empty() { + return BlockchainTests::new(format!("BlockchainTests/GeneralStateTests/{}", stringify!($fork_or_testname))).run(); + } + $(BlockchainTests::new(format!("blockchain_tests/{}/{}/{}", stringify!($fork_or_testname), stringify!($test), stringify!($testname))).run();)? + } + }; +} + +#[allow(missing_docs)] +mod general_state_tests { + use crate::testing::{cases::blockchain_test::BlockchainTests, suite::Suite}; + + ///////////////////////////// TESTS FROM EXECUTION LAYER SPEC TESTS ///////////////////////////// + general_state_test!(modexp, byzantium, eip198_modexp_precompile, modexp); + general_state_test!(acl, berlin, eip2930_access_list, acl); + general_state_test!(dup, frontier, opcodes, dup); + general_state_test!(call_and_callcode_gas_calculation, frontier, opcodes, call_and_callcode_gas_calculation); + general_state_test!(chainid, istanbul, eip1344_chainid, chainid); + general_state_test!(dynamic_create2_selfdestruct_collision, cancun, eip6780_selfdestruct, dynamic_create2_selfdestruct_collision); + general_state_test!(selfdestruct, cancun, eip6780_selfdestruct, selfdestruct); + general_state_test!(reentrancy_selfdestruct_revert, cancun, eip6780_selfdestruct, reentrancy_selfdestruct_revert); + general_state_test!(warm_coinbase, shanghai, eip3651_warm_coinbase, warm_coinbase); + general_state_test!(push0, shanghai, eip3855_push0, push0); + general_state_test!(yul_example, homestead, yul, yul_example); + general_state_test!(selfdestruct_balance_bug, paris, security, selfdestruct_balance_bug); + + #[cfg(feature = "failing-tests")] + mod failing_eels_tests { + use super::*; + general_state_test!(withdrawals, shanghai, eip4895_withdrawals, withdrawals); // FAILED + general_state_test!(initcode, shanghai, eip3860_initcode, initcode); // FAILED + } + + /////////////////////////////////// TESTS FROM ETHEREUM/TESTS /////////////////////////////////// + general_state_test!(shanghai, Shanghai); // FAILED + general_state_test!(st_args_zero_one_balance, stArgsZeroOneBalance); + general_state_test!(st_attack, stAttackTest); + general_state_test!(st_bugs, stBugs); + general_state_test!(st_call_codes, stCallCodes); + general_state_test!(st_call_create_call_code, stCallCreateCallCodeTest); + general_state_test!( + st_call_delegate_codes_call_code_homestead, + stCallDelegateCodesCallCodeHomestead + ); + general_state_test!(st_call_delegate_codes_homestead, stCallDelegateCodesHomestead); + general_state_test!(st_chain_id, stChainId); + general_state_test!(st_code_copy_test, stCodeCopyTest); + general_state_test!(st_code_size_limit, stCodeSizeLimit); + general_state_test!(st_delegate_call_test_homestead, stDelegatecallTestHomestead); + general_state_test!(st_eip150_gas_prices, stEIP150singleCodeGasPrices); + general_state_test!(st_eip150, stEIP150Specific); + general_state_test!(st_eip158, stEIP158Specific); + general_state_test!(st_eip2930, stEIP2930); + general_state_test!(st_homestead, stHomesteadSpecific); + general_state_test!(st_init_code, stInitCodeTest); + general_state_test!(st_log, stLogTests); + general_state_test!(st_mem_expanding_eip150_calls, stMemExpandingEIP150Calls); + general_state_test!(st_memory_stress, stMemoryStressTest); + general_state_test!(st_memory, stMemoryTest); + general_state_test!(st_non_zero_calls, stNonZeroCallsTest); + general_state_test!(st_precompiles, stPreCompiledContracts); + general_state_test!(st_precompiles2, stPreCompiledContracts2); + general_state_test!(st_random, stRandom); + general_state_test!(st_random2, stRandom2); + general_state_test!(st_refund, stRefundTest); + general_state_test!(st_return, stReturnDataTest); + general_state_test!(st_self_balance, stSelfBalance); + general_state_test!(st_shift, stShift); + general_state_test!(st_sload, stSLoadTest); + general_state_test!(st_solidity, stSolidityTest); + general_state_test!(st_static_call, stStaticCall); + general_state_test!(st_static_flag, stStaticFlagEnabled); + general_state_test!(st_system_operations, stSystemOperationsTest); + general_state_test!(st_time_consuming, stTimeConsuming); + general_state_test!(st_wallet, stWalletTest); + general_state_test!(st_zero_calls_revert, stZeroCallsRevert); + general_state_test!(st_zero_calls, stZeroCallsTest); + general_state_test!(st_zero_knowledge, stZeroKnowledge); + general_state_test!(st_zero_knowledge2, stZeroKnowledge2); + + #[cfg(feature = "failing-tests")] + mod failing_ethereum_tests { + use super::*; + general_state_test!(st_bad_opcode, stBadOpcode); // FAILED + general_state_test!(st_create2, stCreate2); // FAILED + general_state_test!(st_create, stCreateTest); // FAILED + general_state_test!(st_eip1559, stEIP1559); // FAILED + general_state_test!(st_eip3607, stEIP3607); // FAILED + general_state_test!(st_example, stExample); // FAILED + general_state_test!(st_ext_codehash, stExtCodeHash); // FAILED + general_state_test!(st_quadratic_complexity, stQuadraticComplexityTest); // FAILED + general_state_test!(st_recursive_create, stRecursiveCreate); // FAILED + general_state_test!(st_revert, stRevertTest); // FAILED + general_state_test!(st_special, stSpecialTest); // FAILED + general_state_test!(st_sstore, stSStoreTest); // FAILED + general_state_test!(st_stack, stStackTests); // FAILED + general_state_test!(st_transaction, stTransactionTest); // FAILED + general_state_test!(vm_tests, VMTests); // FAILED + } +} From 106cbb477a81a2ba6893074204edda017aedd516 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 18:38:52 +0530 Subject: [PATCH 02/10] fmt etc --- Cargo.toml | 2 + src/testing/cases/blockchain_test.rs | 92 ++++++++++++++++------------ src/testing/mod.rs | 2 - src/testing/tests/tests.rs | 78 +++++++++++++++-------- 4 files changed, 109 insertions(+), 65 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 9b7a3af..e2cf600 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -81,4 +81,6 @@ libc = "0.2" [features] default = ["jemalloc"] jemalloc = ["dep:tikv-jemallocator"] +testing = [] +failing-tests = [] diff --git a/src/testing/cases/blockchain_test.rs b/src/testing/cases/blockchain_test.rs index 3ab8343..3ad9d52 100644 --- a/src/testing/cases/blockchain_test.rs +++ b/src/testing/cases/blockchain_test.rs @@ -1,20 +1,28 @@ //! Test runners for `BlockchainTests` in -use crate::{execute::GnosisExecutorProvider, testing::{ - models::{BlockchainTest, ForkSpec}, - Case, Error, Suite, -}}; +use crate::{ + execute::GnosisExecutorProvider, + testing::{ + models::{BlockchainTest, ForkSpec}, + Case, Error, Suite, + }, +}; use alloy_rlp::Decodable; use rayon::iter::{ParallelBridge, ParallelIterator}; use reth_chainspec::ChainSpec; use reth_cli::chainspec::parse_genesis; use reth_primitives::{BlockBody, SealedBlock, StaticFileSegment}; use reth_provider::{ - providers::StaticFileWriter, test_utils::create_test_provider_factory_with_chain_spec, BlockReader, DatabaseProviderFactory, HashingWriter, StaticFileProviderFactory, TransactionVariant + providers::StaticFileWriter, test_utils::create_test_provider_factory_with_chain_spec, + DatabaseProviderFactory, HashingWriter, StaticFileProviderFactory, }; use reth_stages::{stages::ExecutionStage, ExecInput, Stage}; -use revm_primitives::Address; -use std::{collections::BTreeMap, fs, path::{Path, PathBuf}, sync::Arc}; +use std::{ + collections::BTreeMap, + fs, + path::{Path, PathBuf}, + sync::Arc, +}; /// A handler for the blockchain test suite. #[derive(Debug)] @@ -52,10 +60,11 @@ impl Case for BlockchainTestCase { path: path.into(), error, })?; - let test = serde_json::from_str(&s).map_err(|error| Error::CouldNotDeserialize { - path: path.into(), - error, - })?; + let test = + serde_json::from_str(&s).map_err(|error| Error::CouldNotDeserialize { + path: path.into(), + error, + })?; test }, skip: should_skip(path), @@ -75,7 +84,9 @@ impl Case for BlockchainTestCase { let chainspec_path = PathBuf::from(env!("CARGO_MANIFEST_DIR")) .join("scripts") .join("chiado_genesis_alloc.json"); - let original_chain_spec: ChainSpec = parse_genesis(chainspec_path.to_str().unwrap()).unwrap().into(); + let original_chain_spec: ChainSpec = parse_genesis(chainspec_path.to_str().unwrap()) + .unwrap() + .into(); // let chain_spec: Arc = Arc::new(chain_spec); // Iterate through test cases, filtering by the network type to exclude specific forks. @@ -97,24 +108,37 @@ impl Case for BlockchainTestCase { | ForkSpec::MergeMeterInitCode | ForkSpec::MergePush0 | ForkSpec::Unknown - | ForkSpec::Berlin - | ForkSpec::London - | ForkSpec::Istanbul ) }) .par_bridge() .try_for_each(|case| { // Create a new test database and initialize a provider for the test case. let mut chain_spec: ChainSpec = case.network.clone().into(); - chain_spec.genesis.config.extra_fields.insert(String::from("eip1559collector"), original_chain_spec.genesis.config.extra_fields.get("eip1559collector").unwrap().clone()); - chain_spec.genesis.config.extra_fields.insert(String::from("blockRewardsContract"), original_chain_spec.genesis.config.extra_fields.get("blockRewardsContract").unwrap().clone()); + chain_spec.genesis.config.extra_fields.insert( + String::from("eip1559collector"), + original_chain_spec + .genesis + .config + .extra_fields + .get("eip1559collector") + .unwrap() + .clone(), + ); + chain_spec.genesis.config.extra_fields.insert( + String::from("blockRewardsContract"), + original_chain_spec + .genesis + .config + .extra_fields + .get("blockRewardsContract") + .unwrap() + .clone(), + ); chain_spec.deposit_contract = original_chain_spec.deposit_contract; let chain_spec: Arc = Arc::new(chain_spec); let provider = create_test_provider_factory_with_chain_spec(chain_spec.clone()); - let provider = provider - .database_provider_rw() - .unwrap(); + let provider = provider.database_provider_rw().unwrap(); // provider. @@ -142,7 +166,10 @@ impl Case for BlockchainTestCase { // Decode and insert blocks, creating a chain of blocks for the test case. let last_block = case.blocks.iter().try_fold(None, |_, block| { let decoded = SealedBlock::decode(&mut block.rlp.as_ref())?; - dbg!("printing block during insertion: {:?}", decoded.clone().try_seal_with_senders().unwrap()); + dbg!( + "printing block during insertion: {:?}", + decoded.clone().try_seal_with_senders().unwrap() + ); provider.insert_historical_block( decoded.clone().try_seal_with_senders().unwrap(), )?; @@ -154,23 +181,12 @@ impl Case for BlockchainTestCase { .unwrap() .commit_without_sync_all() .unwrap(); - let collector_address = chain_spec - .genesis() - .config - .extra_fields - .get("eip1559collector") - .ok_or(Error::Custom("no eip1559collector field".to_string()))?; - let collector_address: Address = serde_json::from_value(collector_address.clone()).unwrap(); - let gnosis_executor_provider = GnosisExecutorProvider::gnosis(chain_spec.clone()); + let gnosis_executor_provider = GnosisExecutorProvider::gnosis(chain_spec.clone()); - let block = provider.sealed_block_with_senders(1.into(), TransactionVariant::NoHash); // Execute the execution stage using the EVM processor factory for the test case // network. - let result = ExecutionStage::new_with_executor( - gnosis_executor_provider, - ) - .execute( + let result = ExecutionStage::new_with_executor(gnosis_executor_provider).execute( &provider, ExecInput { target: last_block.as_ref().map(|b| b.number), @@ -178,7 +194,9 @@ impl Case for BlockchainTestCase { }, ); if let Err(e) = result { - return Err(Error::Custom("error in execution stage".to_string())); + return Err(Error::Custom( + format!("error in execution stage {:?}", e).to_string(), + )); } // Validate the post-state for the test case. @@ -199,12 +217,10 @@ impl Case for BlockchainTestCase { )?; } _ => { - dbg!("step 10/n"); return Err(Error::MissingPostState); - }, + } } - // Drop the provider without committing to the database. drop(provider); Ok(()) diff --git a/src/testing/mod.rs b/src/testing/mod.rs index de6bd41..99aace8 100644 --- a/src/testing/mod.rs +++ b/src/testing/mod.rs @@ -1,7 +1,5 @@ #![allow(dead_code)] #![cfg(test)] -#[cfg(feature = "testing")] - pub mod case; pub mod result; pub mod suite; diff --git a/src/testing/tests/tests.rs b/src/testing/tests/tests.rs index d3cbf03..f021351 100644 --- a/src/testing/tests/tests.rs +++ b/src/testing/tests/tests.rs @@ -23,25 +23,50 @@ mod general_state_tests { general_state_test!(modexp, byzantium, eip198_modexp_precompile, modexp); general_state_test!(acl, berlin, eip2930_access_list, acl); general_state_test!(dup, frontier, opcodes, dup); - general_state_test!(call_and_callcode_gas_calculation, frontier, opcodes, call_and_callcode_gas_calculation); + general_state_test!( + call_and_callcode_gas_calculation, + frontier, + opcodes, + call_and_callcode_gas_calculation + ); general_state_test!(chainid, istanbul, eip1344_chainid, chainid); - general_state_test!(dynamic_create2_selfdestruct_collision, cancun, eip6780_selfdestruct, dynamic_create2_selfdestruct_collision); + general_state_test!( + dynamic_create2_selfdestruct_collision, + cancun, + eip6780_selfdestruct, + dynamic_create2_selfdestruct_collision + ); general_state_test!(selfdestruct, cancun, eip6780_selfdestruct, selfdestruct); - general_state_test!(reentrancy_selfdestruct_revert, cancun, eip6780_selfdestruct, reentrancy_selfdestruct_revert); - general_state_test!(warm_coinbase, shanghai, eip3651_warm_coinbase, warm_coinbase); + general_state_test!( + reentrancy_selfdestruct_revert, + cancun, + eip6780_selfdestruct, + reentrancy_selfdestruct_revert + ); + general_state_test!( + warm_coinbase, + shanghai, + eip3651_warm_coinbase, + warm_coinbase + ); general_state_test!(push0, shanghai, eip3855_push0, push0); general_state_test!(yul_example, homestead, yul, yul_example); - general_state_test!(selfdestruct_balance_bug, paris, security, selfdestruct_balance_bug); + general_state_test!( + selfdestruct_balance_bug, + paris, + security, + selfdestruct_balance_bug + ); #[cfg(feature = "failing-tests")] mod failing_eels_tests { use super::*; - general_state_test!(withdrawals, shanghai, eip4895_withdrawals, withdrawals); // FAILED - general_state_test!(initcode, shanghai, eip3860_initcode, initcode); // FAILED + general_state_test!(withdrawals, shanghai, eip4895_withdrawals, withdrawals); // FAILED + general_state_test!(initcode, shanghai, eip3860_initcode, initcode); // FAILED } - + /////////////////////////////////// TESTS FROM ETHEREUM/TESTS /////////////////////////////////// - general_state_test!(shanghai, Shanghai); // FAILED + general_state_test!(shanghai, Shanghai); // FAILED general_state_test!(st_args_zero_one_balance, stArgsZeroOneBalance); general_state_test!(st_attack, stAttackTest); general_state_test!(st_bugs, stBugs); @@ -51,7 +76,10 @@ mod general_state_tests { st_call_delegate_codes_call_code_homestead, stCallDelegateCodesCallCodeHomestead ); - general_state_test!(st_call_delegate_codes_homestead, stCallDelegateCodesHomestead); + general_state_test!( + st_call_delegate_codes_homestead, + stCallDelegateCodesHomestead + ); general_state_test!(st_chain_id, stChainId); general_state_test!(st_code_copy_test, stCodeCopyTest); general_state_test!(st_code_size_limit, stCodeSizeLimit); @@ -90,20 +118,20 @@ mod general_state_tests { #[cfg(feature = "failing-tests")] mod failing_ethereum_tests { use super::*; - general_state_test!(st_bad_opcode, stBadOpcode); // FAILED - general_state_test!(st_create2, stCreate2); // FAILED - general_state_test!(st_create, stCreateTest); // FAILED - general_state_test!(st_eip1559, stEIP1559); // FAILED - general_state_test!(st_eip3607, stEIP3607); // FAILED - general_state_test!(st_example, stExample); // FAILED - general_state_test!(st_ext_codehash, stExtCodeHash); // FAILED - general_state_test!(st_quadratic_complexity, stQuadraticComplexityTest); // FAILED - general_state_test!(st_recursive_create, stRecursiveCreate); // FAILED - general_state_test!(st_revert, stRevertTest); // FAILED - general_state_test!(st_special, stSpecialTest); // FAILED - general_state_test!(st_sstore, stSStoreTest); // FAILED - general_state_test!(st_stack, stStackTests); // FAILED - general_state_test!(st_transaction, stTransactionTest); // FAILED - general_state_test!(vm_tests, VMTests); // FAILED + general_state_test!(st_bad_opcode, stBadOpcode); // FAILED + general_state_test!(st_create2, stCreate2); // FAILED + general_state_test!(st_create, stCreateTest); // FAILED + general_state_test!(st_eip1559, stEIP1559); // FAILED + general_state_test!(st_eip3607, stEIP3607); // FAILED + general_state_test!(st_example, stExample); // FAILED + general_state_test!(st_ext_codehash, stExtCodeHash); // FAILED + general_state_test!(st_quadratic_complexity, stQuadraticComplexityTest); // FAILED + general_state_test!(st_recursive_create, stRecursiveCreate); // FAILED + general_state_test!(st_revert, stRevertTest); // FAILED + general_state_test!(st_special, stSpecialTest); // FAILED + general_state_test!(st_sstore, stSStoreTest); // FAILED + general_state_test!(st_stack, stStackTests); // FAILED + general_state_test!(st_transaction, stTransactionTest); // FAILED + general_state_test!(vm_tests, VMTests); // FAILED } } From ce5988ed21e2c3d9136190a3e46783106f20d37f Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 18:48:44 +0530 Subject: [PATCH 03/10] added tests for eels --- .github/workflows/test.yml | 2 ++ src/testing/tests/tests.rs | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 633c37e..f0d4065 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -79,6 +79,8 @@ jobs: run: cargo check - name: Test run: cargo test -- --test-threads=1 --nocapture + - name: Test specs (EELS and ethereum/tests) + run: cargo test --features testing docs: name: Docs diff --git a/src/testing/tests/tests.rs b/src/testing/tests/tests.rs index f021351..981f3c7 100644 --- a/src/testing/tests/tests.rs +++ b/src/testing/tests/tests.rs @@ -66,7 +66,6 @@ mod general_state_tests { } /////////////////////////////////// TESTS FROM ETHEREUM/TESTS /////////////////////////////////// - general_state_test!(shanghai, Shanghai); // FAILED general_state_test!(st_args_zero_one_balance, stArgsZeroOneBalance); general_state_test!(st_attack, stAttackTest); general_state_test!(st_bugs, stBugs); @@ -118,6 +117,7 @@ mod general_state_tests { #[cfg(feature = "failing-tests")] mod failing_ethereum_tests { use super::*; + general_state_test!(shanghai, Shanghai); // FAILED general_state_test!(st_bad_opcode, stBadOpcode); // FAILED general_state_test!(st_create2, stCreate2); // FAILED general_state_test!(st_create, stCreateTest); // FAILED From 2f9bb3331d37deee05664382b23175feca5ad37c Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 19:01:55 +0530 Subject: [PATCH 04/10] downloads the folders --- .github/workflows/test.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f0d4065..dc2435c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -79,6 +79,10 @@ jobs: run: cargo check - name: Test run: cargo test -- --test-threads=1 --nocapture + - name: Downloading ethereum/tests + run: git clone https://github.com/ethereum/tests ethereum-tests + - name: Downloading EELS fixtures released at Cancun + run: curl -LO https://github.com/ethereum/execution-spec-tests/releases/download/v2.1.1/fixtures.tar.gz && tar -xzf fixtures.tar.gz - name: Test specs (EELS and ethereum/tests) run: cargo test --features testing From 1783e4b7d2de938e6eb9504536276dd864d07e82 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 19:16:35 +0530 Subject: [PATCH 05/10] new job for spec tests --- .github/workflows/test.yml | 30 ++++++++++++++++++++++++------ 1 file changed, 24 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index dc2435c..e2e3847 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -34,6 +34,30 @@ jobs: - run: cargo check --all-targets - run: cargo clippy -- --deny warnings + spec-tests: + name: Spec tests + runs-on: 'ubuntu-latest' + steps: + - uses: actions/checkout@v3 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + - name: Install rust + uses: dtolnay/rust-toolchain@master + with: + toolchain: ${{ matrix.rust || 'stable' }} + targets: ${{ matrix.target }} + - name: Downloading ethereum/tests + run: git clone https://github.com/ethereum/tests ethereum-tests + - name: Downloading EELS fixtures released at Cancun + run: curl -LO https://github.com/ethereum/execution-spec-tests/releases/download/v2.1.1/fixtures.tar.gz && tar -xzf fixtures.tar.gz + - name: Test specs (EELS and ethereum/tests) + run: cargo test --features testing + tests: name: Tests ${{ matrix.name }} needs: [style] @@ -79,12 +103,6 @@ jobs: run: cargo check - name: Test run: cargo test -- --test-threads=1 --nocapture - - name: Downloading ethereum/tests - run: git clone https://github.com/ethereum/tests ethereum-tests - - name: Downloading EELS fixtures released at Cancun - run: curl -LO https://github.com/ethereum/execution-spec-tests/releases/download/v2.1.1/fixtures.tar.gz && tar -xzf fixtures.tar.gz - - name: Test specs (EELS and ethereum/tests) - run: cargo test --features testing docs: name: Docs From 10e4764adfc133b971b09b8c58f91759e58bfac3 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 19:32:54 +0530 Subject: [PATCH 06/10] updated cargo.lock --- Cargo.lock | 361 +++++++++++++++++-------------------- Cargo.toml | 3 +- src/testing/tests/tests.rs | 38 ++-- 3 files changed, 186 insertions(+), 216 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 5fbcb5e..9ecf5d6 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -91,9 +91,9 @@ dependencies = [ [[package]] name = "allocator-api2" -version = "0.2.20" +version = "0.2.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45862d1c77f2228b9e10bc609d5bc203d86ebc9b87ad8d5d5167a6c9abf739d9" +checksum = "683d7910e743518b0e34f1186f92494becacb047c7b6bf616c96772180fef923" [[package]] name = "alloy-chains" @@ -131,9 +131,9 @@ dependencies = [ [[package]] name = "alloy-dyn-abi" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cf633ae9a1f0c82fdb9e559ed2be1c8e415c3e48fc47e1feaf32c6078ec0cdd" +checksum = "80759b3f57b3b20fa7cd8fef6479930fc95461b58ff8adea6e87e618449c8a1d" dependencies = [ "alloy-json-abi", "alloy-primitives", @@ -208,9 +208,9 @@ dependencies = [ [[package]] name = "alloy-json-abi" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a500037938085feed8a20dbfc8fce58c599db68c948cfae711147175dee392c" +checksum = "ac4b22b3e51cac09fd2adfcc73b55f447b4df669f983c13f7894ec82b607c63f" dependencies = [ "alloy-primitives", "alloy-sol-type-parser", @@ -270,9 +270,9 @@ dependencies = [ [[package]] name = "alloy-primitives" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3aeeb5825c2fc8c2662167058347cd0cafc3cb15bcb5cdb1758a63c2dca0409e" +checksum = "9db948902dfbae96a73c2fbf1f7abec62af034ab883e4c777c3fd29702bd6e2c" dependencies = [ "alloy-rlp", "arbitrary", @@ -285,7 +285,7 @@ dependencies = [ "getrandom", "hashbrown 0.15.2", "hex-literal", - "indexmap 2.6.0", + "indexmap 2.7.0", "itoa", "k256", "keccak-asm", @@ -294,7 +294,7 @@ dependencies = [ "proptest-derive", "rand", "ruint", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "serde", "sha3", "tiny-keccak", @@ -377,7 +377,7 @@ checksum = "2b09cae092c27b6f1bde952653a22708691802e57bfef4a2973b80bea21efd3f" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -589,56 +589,56 @@ dependencies = [ [[package]] name = "alloy-sol-macro" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5c0279d09463a4695788a3622fd95443625f7be307422deba4b55dd491a9c7a1" +checksum = "3bfd7853b65a2b4f49629ec975fee274faf6dff15ab8894c620943398ef283c0" dependencies = [ "alloy-sol-macro-expander", "alloy-sol-macro-input", "proc-macro-error2", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] name = "alloy-sol-macro-expander" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4feea540fc8233df2ad1156efd744b2075372f43a8f942a68b3b19c8a00e2c12" +checksum = "82ec42f342d9a9261699f8078e57a7a4fda8aaa73c1a212ed3987080e6a9cd13" dependencies = [ "alloy-sol-macro-input", "const-hex", "heck", - "indexmap 2.6.0", + "indexmap 2.7.0", "proc-macro-error2", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "syn-solidity", "tiny-keccak", ] [[package]] name = "alloy-sol-macro-input" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0ad281f3d1b613af814b66977ee698e443d4644a1510962d0241f26e0e53ae" +checksum = "ed2c50e6a62ee2b4f7ab3c6d0366e5770a21cad426e109c2f40335a1b3aff3df" dependencies = [ "const-hex", "dunce", "heck", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "syn-solidity", ] [[package]] name = "alloy-sol-type-parser" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96eff16c797438add6c37bb335839d015b186c5421ee5626f5559a7bfeb38ef5" +checksum = "ac17c6e89a50fb4a758012e4b409d9a0ba575228e69b539fe37d7a1bd507ca4a" dependencies = [ "serde", "winnow", @@ -646,9 +646,9 @@ dependencies = [ [[package]] name = "alloy-sol-types" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cff34e0682d6665da243a3e81da96f07a2dd50f7e64073e382b1a141f5a2a2f6" +checksum = "c9dc0fffe397aa17628160e16b89f704098bf3c9d74d5d369ebc239575936de5" dependencies = [ "alloy-json-abi", "alloy-primitives", @@ -811,7 +811,7 @@ dependencies = [ "proc-macro-error2", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1003,7 +1003,7 @@ checksum = "c7c24de15d275a1ecfd47a380fb4d5ec9bfe0933f309ed5e705b775596a3574d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1014,7 +1014,7 @@ checksum = "721cae7de5c34fbb2acd27e21e6d2cf7b886dce0c27388d46c4e6c47ea4318dd" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1052,7 +1052,7 @@ checksum = "3c87f3f15e7794432337fc718554eaa4dc8f04c9677a950ffe366f20a162ae42" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1152,7 +1152,7 @@ dependencies = [ "regex", "rustc-hash 1.1.0", "shlex", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1247,9 +1247,9 @@ dependencies = [ "bitflags 2.6.0", "boa_interner", "boa_macros", - "indexmap 2.6.0", + "indexmap 2.7.0", "num-bigint", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", ] [[package]] @@ -1273,7 +1273,7 @@ dependencies = [ "fast-float", "hashbrown 0.14.5", "icu_normalizer", - "indexmap 2.6.0", + "indexmap 2.7.0", "intrusive-collections", "itertools 0.13.0", "num-bigint", @@ -1285,7 +1285,7 @@ dependencies = [ "portable-atomic", "rand", "regress", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "ryu-js", "serde", "serde_json", @@ -1319,10 +1319,10 @@ dependencies = [ "boa_gc", "boa_macros", "hashbrown 0.14.5", - "indexmap 2.6.0", + "indexmap 2.7.0", "once_cell", "phf", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "static_assertions", ] @@ -1334,7 +1334,7 @@ checksum = "240f4126219a83519bad05c9a40bfc0303921eeb571fc2d7e44c17ffac99d3f1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "synstructure", ] @@ -1354,7 +1354,7 @@ dependencies = [ "num-bigint", "num-traits", "regress", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", ] [[package]] @@ -1371,7 +1371,7 @@ checksum = "ae85205289bab1f2c7c8a30ddf0541cf89ba2ff7dbd144feef50bbfa664288d4" dependencies = [ "fast-float", "paste", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "sptr", "static_assertions", ] @@ -1455,7 +1455,7 @@ checksum = "bcfcc3cd946cb52f0bbfdbbcfa2f4e24f75ebb6c0e1002f7c25904fada18b9ec" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1466,9 +1466,9 @@ checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" [[package]] name = "bytes" -version = "1.8.0" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ac0150caa2ae65ca5bd83f25c7de183dea78d4d366469f148435e2acfbad0da" +checksum = "325918d6fe32f23b19878fe4b34794ae41fc19ddbe53b10571a4874d44ffd39b" dependencies = [ "serde", ] @@ -1499,9 +1499,9 @@ dependencies = [ [[package]] name = "cargo-platform" -version = "0.1.8" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24b1f0365a6c6bb4020cd05806fd0d33c44d38046b8bd7f0e40814b9763cabfc" +checksum = "e35af189006b9c0f00a064685c727031e3ed2d8020f7ba284d78cc2671bd36ea" dependencies = [ "serde", ] @@ -1537,9 +1537,9 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.1" +version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd9de9f2205d5ef3fd67e685b0df337994ddd4495e2a28d185500d0e1edfea47" +checksum = "f34d93e62b03caf570cccc334cbc6c2fceca82f39211051345108adcba3eebdc" dependencies = [ "jobserver", "libc", @@ -1640,7 +1640,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1714,9 +1714,9 @@ dependencies = [ [[package]] name = "const-hex" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "487981fa1af147182687064d0a2c336586d337a606595ced9ffb0c685c250c73" +checksum = "4b0485bab839b018a8f1723fc5391819fea5f8f0f32288ef8a735fd096b6160c" dependencies = [ "cfg-if", "cpufeatures", @@ -1867,7 +1867,7 @@ checksum = "829d955a0bb380ef178a640b91779e3987da38c9aea133b20614cfed8cdea9c6" dependencies = [ "bitflags 2.6.0", "crossterm_winapi", - "mio 1.0.2", + "mio 1.0.3", "parking_lot", "rustix", "signal-hook", @@ -1956,7 +1956,7 @@ checksum = "f46882e17999c6cc590af592290432be3bce0428cb0d5f8b6715e4dc7b383eb3" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1980,7 +1980,7 @@ dependencies = [ "proc-macro2", "quote", "strsim", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -1991,7 +1991,7 @@ checksum = "d336a2a514f6ccccaa3e09b02d41d35330c07ddf03a62165fcec10bb561c7806" dependencies = [ "darling_core", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2104,7 +2104,7 @@ checksum = "30542c1ad912e0e3d22a1935c290e12e8a29d704a420177a31faad4a601a0800" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2125,7 +2125,7 @@ dependencies = [ "convert_case", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "unicode-xid", ] @@ -2239,7 +2239,7 @@ checksum = "97369cbbc041bc366949bc74d34658d6cda5621039731c6310521892a3a20ae0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2359,7 +2359,7 @@ dependencies = [ "heck", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2370,7 +2370,7 @@ checksum = "2f9ed6b3789237c8a0c1c505af1c7eb2c560df6186f01b098c3a1064ea532f38" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2381,12 +2381,12 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.9" +version = "0.3.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" +checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" dependencies = [ "libc", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -2574,7 +2574,7 @@ checksum = "162ee34ebcb7c64a8abebc059ce0fee27c2262618d7b60ed8faf72fef13c3650" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -2739,7 +2739,7 @@ dependencies = [ "futures-core", "futures-sink", "http", - "indexmap 2.6.0", + "indexmap 2.7.0", "slab", "tokio", "tokio-util", @@ -2918,9 +2918,9 @@ dependencies = [ [[package]] name = "http-range-header" -version = "0.4.1" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "08a397c49fec283e3d6211adbe480be95aae5f304cfb923e9970e08956d5168a" +checksum = "9171a2ea8a68358193d15dd5d70c1c10a2afc3e7e4c5bc92bc9f025cebd7359c" [[package]] name = "httparse" @@ -3153,7 +3153,7 @@ checksum = "1ec89e9337638ecdc08744df490b221a7399bf8d164eb52a665454e60e075ad6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3220,7 +3220,7 @@ checksum = "a0eb5a3343abf848c0984fe4604b2b105da9539376e24fc0a3b0007411ae4fd9" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3261,9 +3261,9 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.6.0" +version = "2.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "707907fe3c25f5424cce2cb7e1cbcafee6bdbe735ca90ef77c29e84591e5b9da" +checksum = "62f822373a4fe84d4bb149bf54e584a7f4abec90e072ed49cda0edea5b95471f" dependencies = [ "arbitrary", "equivalent", @@ -3318,7 +3318,7 @@ dependencies = [ "pretty_assertions", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3434,10 +3434,11 @@ dependencies = [ [[package]] name = "js-sys" -version = "0.3.72" +version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" +checksum = "a865e038f7f6ed956f788f0d7d60c541fff74c7bd74272c5d4cf15c63743e705" dependencies = [ + "once_cell", "wasm-bindgen", ] @@ -3501,7 +3502,7 @@ dependencies = [ "parking_lot", "pin-project", "rand", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "serde", "serde_json", "thiserror 1.0.69", @@ -3546,7 +3547,7 @@ dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3706,15 +3707,15 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.166" +version = "0.2.167" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2ccc108bbc0b1331bd061864e7cd823c0cab660bbe6970e66e2c0614decde36" +checksum = "09d6582e104315a817dff97f75133544b2e094ee22447d2acf4a74e189ba06fc" [[package]] name = "libloading" -version = "0.8.5" +version = "0.8.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4979f22fdb869068da03c9f7528f8297c6fd2606bc3a4affe42e6a823fdb8da4" +checksum = "fc2f4eb4bc735547cfed7c0a4922cbd04a4655978c09b54f1f7b228750664c34" dependencies = [ "cfg-if", "windows-targets 0.52.6", @@ -3951,7 +3952,7 @@ dependencies = [ "proc-macro2", "quote", "regex", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -3961,7 +3962,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "85b6f8152da6d7892ff1b7a1c0fa3f435e92b5918ad67035c3bb432111d9a29b" dependencies = [ "base64 0.22.1", - "indexmap 2.6.0", + "indexmap 2.7.0", "metrics", "metrics-util", "quanta", @@ -4043,11 +4044,10 @@ dependencies = [ [[package]] name = "mio" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80e04d1dcff3aae0704555fe5fee3bcfaf3d1fdf8a7e521d5b9d2b42acb52cec" +checksum = "2886843bf800fba2e3377cff24abf6379b4c4d5c6681eaf9ea5b0d15090450bd" dependencies = [ - "hermit-abi", "libc", "log", "wasi", @@ -4159,16 +4159,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "nu-ansi-term" -version = "0.46.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" -dependencies = [ - "overload", - "winapi", -] - [[package]] name = "num" version = "0.4.3" @@ -4278,7 +4268,7 @@ dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -4378,12 +4368,6 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" -[[package]] -name = "overload" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" - [[package]] name = "page_size" version = "0.6.0" @@ -4396,9 +4380,9 @@ dependencies = [ [[package]] name = "parity-scale-codec" -version = "3.7.0" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8be4817d39f3272f69c59fe05d0535ae6456c2dc2fa1ba02910296c7e0a5c590" +checksum = "306800abfa29c7f16596b5970a588435e3d5b3149683d00c12b699cc19f895ee" dependencies = [ "arbitrary", "arrayvec", @@ -4407,20 +4391,19 @@ dependencies = [ "bytes", "impl-trait-for-tuples", "parity-scale-codec-derive", - "rustversion", "serde", ] [[package]] name = "parity-scale-codec-derive" -version = "3.7.0" +version = "3.6.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8781a75c6205af67215f382092b6e0a4ff3734798523e69073d4bcd294ec767b" +checksum = "d830939c76d294956402033aee57a6da7b438f2294eb94864c37b0569053a42c" dependencies = [ "proc-macro-crate", "proc-macro2", "quote", - "syn 2.0.89", + "syn 1.0.109", ] [[package]] @@ -4519,7 +4502,7 @@ dependencies = [ "phf_shared", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -4548,7 +4531,7 @@ checksum = "3c0f5fad0874fc7abcd4d750e76917eaebbecaa2c20bde22e1dbeeba8beb758c" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -4676,7 +4659,7 @@ dependencies = [ "proc-macro-error-attr2", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -4774,7 +4757,7 @@ checksum = "6ff7ff745a347b87471d859a377a9a404361e7efc2a971d73424a6d183c0fc77" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -4817,7 +4800,7 @@ dependencies = [ "pin-project-lite", "quinn-proto", "quinn-udp", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "rustls", "socket2", "thiserror 2.0.3", @@ -4835,7 +4818,7 @@ dependencies = [ "getrandom", "rand", "ring", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "rustls", "rustls-pki-types", "slab", @@ -5460,7 +5443,7 @@ dependencies = [ "convert_case", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -5555,7 +5538,7 @@ dependencies = [ "reth-storage-errors", "reth-tracing", "reth-trie-common", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "serde", "strum", "sysinfo", @@ -6036,7 +6019,7 @@ dependencies = [ "once_cell", "proptest", "proptest-derive", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "serde", "thiserror-no-std", ] @@ -6270,7 +6253,7 @@ dependencies = [ "byteorder", "dashmap 6.1.0", "derive_more", - "indexmap 2.6.0", + "indexmap 2.7.0", "parking_lot", "reth-mdbx-sys", "smallvec", @@ -6363,7 +6346,7 @@ dependencies = [ "reth-tasks", "reth-tokio-util", "reth-transaction-pool", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "schnellru", "secp256k1", "serde", @@ -6907,7 +6890,7 @@ dependencies = [ "reth-prune-types", "reth-static-file-types", "reth-tokio-util", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "thiserror 1.0.69", "tokio", "tracing", @@ -7456,7 +7439,7 @@ dependencies = [ "reth-storage-api", "reth-tasks", "revm", - "rustc-hash 2.0.0", + "rustc-hash 2.1.0", "schnellru", "serde", "smallvec", @@ -7584,6 +7567,7 @@ dependencies = [ "reth-basic-payload-builder", "reth-chain-state", "reth-chainspec", + "reth-cli", "reth-cli-util", "reth-consensus", "reth-db", @@ -7854,9 +7838,9 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustc-hash" -version = "2.0.0" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "583034fd73374156e66797ed8e5b0d5690409c9226b22d87cb7f19821c05d152" +checksum = "c7fb8039b3032c191086b10f11f319a6e99e1e82889c5cc6046f515c9db1d497" dependencies = [ "rand", ] @@ -8161,7 +8145,7 @@ checksum = "ad1e866f866923f252f05c889987993144fb74e722403468a4ebd70c3cd756c0" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8170,7 +8154,7 @@ version = "1.0.133" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c7fceb2473b9166b2294ef05efcb65a3db80803f0b03ef86a5fc88a2b85ee377" dependencies = [ - "indexmap 2.6.0", + "indexmap 2.7.0", "itoa", "memchr", "ryu", @@ -8208,7 +8192,7 @@ dependencies = [ "chrono", "hex", "indexmap 1.9.3", - "indexmap 2.6.0", + "indexmap 2.7.0", "serde", "serde_derive", "serde_json", @@ -8225,7 +8209,7 @@ dependencies = [ "darling", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8324,7 +8308,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "34db1a06d485c9142248b7a054f034b349b212551f3dfd19c94d45a754a217cd" dependencies = [ "libc", - "mio 1.0.2", + "mio 1.0.3", "signal-hook", ] @@ -8419,9 +8403,9 @@ checksum = "1b6b67fb9a61334225b5b790716f609cd58395f895b3fe8b328786812a40bc3b" [[package]] name = "socket2" -version = "0.5.7" +version = "0.5.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ce305eb0b4296696835b71df73eb912e0f1ffd2556a501fcede6e0c50349191c" +checksum = "c970269d99b64e60ec3bd6ad27270092a5394c4e309314b18ae3fe575695fbe8" dependencies = [ "libc", "windows-sys 0.52.0", @@ -8429,9 +8413,9 @@ dependencies = [ [[package]] name = "soketto" -version = "0.8.0" +version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37468c595637c10857701c990f93a40ce0e357cedb0953d1c26c8d8027f9bb53" +checksum = "2e859df029d160cb88608f5d7df7fb4753fd20fdfb4de5644f3d8b8440841721" dependencies = [ "base64 0.22.1", "bytes", @@ -8502,7 +8486,7 @@ dependencies = [ "proc-macro2", "quote", "rustversion", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8537,9 +8521,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.89" +version = "2.0.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44d46482f1c1c87acd84dea20c1bf5ebff4c757009ed6bf19cfd36fb10e92c4e" +checksum = "919d3b74a5dd0ccd15aeb8f93e7006bd9e14c295087c9896a110f490752bcf31" dependencies = [ "proc-macro2", "quote", @@ -8548,14 +8532,14 @@ dependencies = [ [[package]] name = "syn-solidity" -version = "0.8.13" +version = "0.8.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bdaa7b9e815582ba343a20c66627437cf45f1c6fba7f69772cbfd1358c7e197" +checksum = "da0523f59468a2696391f2a772edc089342aacd53c3caa2ac3264e598edf119b" dependencies = [ "paste", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8581,7 +8565,7 @@ checksum = "c8af7666ab7b6390ab78131fb5b0fce11d6b7a6951602017c35fa82800708971" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8648,7 +8632,7 @@ checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8659,7 +8643,7 @@ checksum = "f077553d607adc1caf65430528a576c757a71ed73944b66ebb58ef2bbd243568" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8734,9 +8718,9 @@ dependencies = [ [[package]] name = "time" -version = "0.3.36" +version = "0.3.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" +checksum = "35e7868883861bd0e56d9ac6efcaaca0d6d5d82a2a7ec8209ff492c07cf37b21" dependencies = [ "deranged", "itoa", @@ -8758,9 +8742,9 @@ checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" [[package]] name = "time-macros" -version = "0.2.18" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" +checksum = "2834e6017e3e5e4b9834939793b282bc03b37a3336245fa820e35e233e2a85de" dependencies = [ "num-conv", "time-core", @@ -8802,14 +8786,14 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.41.1" +version = "1.42.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22cfb5bee7a6a52939ca9224d6ac897bb669134078daa8735560897f69de4d33" +checksum = "5cec9b21b0450273377fc97bd4c33a8acffc8c996c987a7c5b319a0083707551" dependencies = [ "backtrace", "bytes", "libc", - "mio 1.0.2", + "mio 1.0.3", "parking_lot", "pin-project-lite", "signal-hook-registry", @@ -8826,7 +8810,7 @@ checksum = "693d596312e88961bc67d7f1f97af8a70227d9f90c31bba5806eec004978d752" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -8910,7 +8894,7 @@ version = "0.22.22" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4ae48d6208a266e853d946088ed816055e556cc6028c5e8e2b84d9fa5dd7c7f5" dependencies = [ - "indexmap 2.6.0", + "indexmap 2.7.0", "serde", "serde_spanned", "toml_datetime", @@ -9027,7 +9011,7 @@ checksum = "395ae124c09f9e6918a2310af6038fba074bcf474ac352496d5910dd59a2226d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9052,26 +9036,15 @@ dependencies = [ [[package]] name = "tracing-journald" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba316a74e8fc3c3896a850dba2375928a9fa171b085ecddfc7c054d39970f3fd" +checksum = "fc0b4143302cf1022dac868d521e36e8b27691f72c84b3311750d5188ebba657" dependencies = [ "libc", "tracing-core", "tracing-subscriber", ] -[[package]] -name = "tracing-log" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" -dependencies = [ - "log", - "once_cell", - "tracing-core", -] - [[package]] name = "tracing-logfmt" version = "0.3.5" @@ -9086,9 +9059,9 @@ dependencies = [ [[package]] name = "tracing-serde" -version = "0.1.3" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc6b213177105856957181934e4920de57730fc69bf42c37ee5bb664d406d9e1" +checksum = "704b1aeb7be0d0a84fc9828cae51dab5970fee5088f83d1dd7ee6f6246fc6ff1" dependencies = [ "serde", "tracing-core", @@ -9096,22 +9069,19 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.18" +version = "0.3.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" +checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008" dependencies = [ "matchers", - "nu-ansi-term", "once_cell", "regex", "serde", "serde_json", "sharded-slab", - "smallvec", "thread_local", "tracing", "tracing-core", - "tracing-log", "tracing-serde", ] @@ -9402,7 +9372,7 @@ checksum = "d674d135b4a8c1d7e813e2f8d1c9a58308aee4a680323066025e53132218bd91" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9441,9 +9411,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.95" +version = "0.2.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" +checksum = "d15e63b4482863c109d70a7b8706c1e364eb6ea449b201a76c5b89cedcec2d5c" dependencies = [ "cfg-if", "once_cell", @@ -9452,36 +9422,37 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.95" +version = "0.2.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" +checksum = "8d36ef12e3aaca16ddd3f67922bc63e48e953f126de60bd33ccc0101ef9998cd" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.45" +version = "0.4.47" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc7ec4f8827a71586374db3e87abdb5a2bb3a15afed140221307c3ec06b1f63b" +checksum = "9dfaf8f50e5f293737ee323940c7d8b08a66a95a419223d9f41610ca08b0833d" dependencies = [ "cfg-if", "js-sys", + "once_cell", "wasm-bindgen", "web-sys", ] [[package]] name = "wasm-bindgen-macro" -version = "0.2.95" +version = "0.2.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" +checksum = "705440e08b42d3e4b36de7d66c944be628d579796b8090bfa3471478a2260051" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -9489,22 +9460,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.95" +version = "0.2.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" +checksum = "98c9ae5a76e46f4deecd0f0255cc223cfa18dc9b261213b8aa0c7b36f61b3f1d" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.95" +version = "0.2.97" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" +checksum = "6ee99da9c5ba11bd675621338ef6fa52296b76b83305e9b6e5c77d4c286d6d49" [[package]] name = "wasmtimer" @@ -9522,9 +9493,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.72" +version = "0.3.74" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6488b90108c040df0fe62fa815cbdee25124641df01814dd7282749234c6112" +checksum = "a98bc3c33f0fe7e59ad7cd041b89034fa82a7c2d4365ca538dda6cdaf513863c" dependencies = [ "js-sys", "wasm-bindgen", @@ -9648,7 +9619,7 @@ checksum = "9107ddc059d5b6fbfbffdfa7a7fe3e22a226def0b2608f72e9d552763d3e1ad7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9659,7 +9630,7 @@ checksum = "2bbd5b46c938e506ecbce286b6628a02171d56153ba733b6c741fc627ec9579b" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9670,7 +9641,7 @@ checksum = "29bee4b38ea3cde66011baa44dba677c432a78593e202392d1e9070cf2a7fca7" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9681,7 +9652,7 @@ checksum = "053c4c462dc91d3b1504c6fe5a726dd15e216ba718e84a0e46a88fbe5ded3515" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9956,7 +9927,7 @@ checksum = "2380878cad4ac9aac1e2435f3eb4020e8374b5f13c296cb75b4620ff8e229154" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "synstructure", ] @@ -9978,7 +9949,7 @@ checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -9998,7 +9969,7 @@ checksum = "595eed982f7d355beb85837f651fa22e90b3c044842dc7f2c2842c086f295808" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", "synstructure", ] @@ -10019,7 +9990,7 @@ checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] @@ -10041,7 +10012,7 @@ checksum = "6eafa6dfb17584ea3e2bd6e76e0cc15ad7af12b09abdd1ca55961bed9b1063c6" dependencies = [ "proc-macro2", "quote", - "syn 2.0.89", + "syn 2.0.90", ] [[package]] diff --git a/Cargo.toml b/Cargo.toml index e2cf600..acb67e2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -82,5 +82,4 @@ libc = "0.2" default = ["jemalloc"] jemalloc = ["dep:tikv-jemallocator"] testing = [] -failing-tests = [] - +failing-tests = [] \ No newline at end of file diff --git a/src/testing/tests/tests.rs b/src/testing/tests/tests.rs index 981f3c7..d39965f 100644 --- a/src/testing/tests/tests.rs +++ b/src/testing/tests/tests.rs @@ -61,8 +61,8 @@ mod general_state_tests { #[cfg(feature = "failing-tests")] mod failing_eels_tests { use super::*; - general_state_test!(withdrawals, shanghai, eip4895_withdrawals, withdrawals); // FAILED - general_state_test!(initcode, shanghai, eip3860_initcode, initcode); // FAILED + general_state_test!(withdrawals, shanghai, eip4895_withdrawals, withdrawals); + general_state_test!(initcode, shanghai, eip3860_initcode, initcode); } /////////////////////////////////// TESTS FROM ETHEREUM/TESTS /////////////////////////////////// @@ -104,7 +104,6 @@ mod general_state_tests { general_state_test!(st_shift, stShift); general_state_test!(st_sload, stSLoadTest); general_state_test!(st_solidity, stSolidityTest); - general_state_test!(st_static_call, stStaticCall); general_state_test!(st_static_flag, stStaticFlagEnabled); general_state_test!(st_system_operations, stSystemOperationsTest); general_state_test!(st_time_consuming, stTimeConsuming); @@ -117,21 +116,22 @@ mod general_state_tests { #[cfg(feature = "failing-tests")] mod failing_ethereum_tests { use super::*; - general_state_test!(shanghai, Shanghai); // FAILED - general_state_test!(st_bad_opcode, stBadOpcode); // FAILED - general_state_test!(st_create2, stCreate2); // FAILED - general_state_test!(st_create, stCreateTest); // FAILED - general_state_test!(st_eip1559, stEIP1559); // FAILED - general_state_test!(st_eip3607, stEIP3607); // FAILED - general_state_test!(st_example, stExample); // FAILED - general_state_test!(st_ext_codehash, stExtCodeHash); // FAILED - general_state_test!(st_quadratic_complexity, stQuadraticComplexityTest); // FAILED - general_state_test!(st_recursive_create, stRecursiveCreate); // FAILED - general_state_test!(st_revert, stRevertTest); // FAILED - general_state_test!(st_special, stSpecialTest); // FAILED - general_state_test!(st_sstore, stSStoreTest); // FAILED - general_state_test!(st_stack, stStackTests); // FAILED - general_state_test!(st_transaction, stTransactionTest); // FAILED - general_state_test!(vm_tests, VMTests); // FAILED + general_state_test!(shanghai, Shanghai); + general_state_test!(st_bad_opcode, stBadOpcode); + general_state_test!(st_create2, stCreate2); + general_state_test!(st_create, stCreateTest); + general_state_test!(st_eip1559, stEIP1559); + general_state_test!(st_eip3607, stEIP3607); + general_state_test!(st_example, stExample); + general_state_test!(st_ext_codehash, stExtCodeHash); + general_state_test!(st_quadratic_complexity, stQuadraticComplexityTest); + general_state_test!(st_recursive_create, stRecursiveCreate); + general_state_test!(st_revert, stRevertTest); + general_state_test!(st_special, stSpecialTest); + general_state_test!(st_sstore, stSStoreTest); + general_state_test!(st_stack, stStackTests); + general_state_test!(st_static_call, stStaticCall); // passing, but conflicts with rewards contract + general_state_test!(st_transaction, stTransactionTest); + general_state_test!(vm_tests, VMTests); } } From 362af8fb0a33f78d3db202bfb545e15e5026ea01 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 23:26:07 +0530 Subject: [PATCH 07/10] removed consensus and upgraded to newer --- Cargo.lock | 570 ++++++++++++++++++++++++----------------- Cargo.toml | 70 ++--- src/evm_config.rs | 4 +- src/execute.rs | 28 +- src/lib.rs | 44 +++- src/payload_builder.rs | 163 ++++++++---- 6 files changed, 545 insertions(+), 334 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 9ecf5d6..68a520f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -112,14 +112,15 @@ dependencies = [ [[package]] name = "alloy-consensus" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae09ffd7c29062431dd86061deefe4e3c6f07fa0d674930095f8dcedb0baf02c" +checksum = "73dd0ab7003dfa3efd252e423873cd3bc241d1456147e752f995cc8aabd1d1f6" dependencies = [ "alloy-eips", "alloy-primitives", "alloy-rlp", "alloy-serde", + "alloy-trie", "arbitrary", "auto_impl", "c-kzg", @@ -129,6 +130,20 @@ dependencies = [ "serde_with", ] +[[package]] +name = "alloy-consensus-any" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d08234c0eece0e08602db5095a16dc942cad91967cccfcfc2c6a42c25563964f" +dependencies = [ + "alloy-consensus", + "alloy-eips", + "alloy-primitives", + "alloy-rlp", + "alloy-serde", + "serde", +] + [[package]] name = "alloy-dyn-abi" version = "0.8.14" @@ -178,9 +193,9 @@ dependencies = [ [[package]] name = "alloy-eips" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b6aa3961694b30ba53d41006131a2fca3bdab22e4c344e46db2c639e7c2dfdd" +checksum = "50c242de43a1869bcb2fbce3b377130959d10dfd562b87ac7aa2f04d98baac51" dependencies = [ "alloy-eip2930", "alloy-eip7702", @@ -197,9 +212,9 @@ dependencies = [ [[package]] name = "alloy-genesis" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e53f7877ded3921d18a0a9556d55bedf84535567198c9edab2aa23106da91855" +checksum = "9dd39b72f860cb0c542fac925f91d1939c2b14a0970b39d0ae304b5b7574a0ac" dependencies = [ "alloy-primitives", "alloy-serde", @@ -220,29 +235,31 @@ dependencies = [ [[package]] name = "alloy-json-rpc" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3694b7e480728c0b3e228384f223937f14c10caef5a4c766021190fc8f283d35" +checksum = "6c15c11661571a19a06896663c93e804ccf013159275a89a98e892014df514d8" dependencies = [ "alloy-primitives", "alloy-sol-types", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tracing", ] [[package]] name = "alloy-network" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea94b8ceb5c75d7df0a93ba0acc53b55a22b47b532b600a800a87ef04eb5b0b4" +checksum = "60dd0b99eaa5e715dd90d42021f7f08a0a70976ea84f41a0ad233770e0c1962b" dependencies = [ "alloy-consensus", + "alloy-consensus-any", "alloy-eips", "alloy-json-rpc", "alloy-network-primitives", "alloy-primitives", + "alloy-rpc-types-any", "alloy-rpc-types-eth", "alloy-serde", "alloy-signer", @@ -252,14 +269,14 @@ dependencies = [ "futures-utils-wasm", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "alloy-network-primitives" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "df9f3e281005943944d15ee8491534a1c7b3cbf7a7de26f8c433b842b93eb5f9" +checksum = "18abfc73ce48f074c8bc6e05c1f08ef0b1ddc9b04f191a821d0beb9470a42a29" dependencies = [ "alloy-consensus", "alloy-eips", @@ -302,9 +319,9 @@ dependencies = [ [[package]] name = "alloy-provider" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "40c1f9eede27bf4c13c099e8e64d54efd7ce80ef6ea47478aa75d5d74e2dba3b" +checksum = "4933c761f10e44d5e901804b56efb2ce6e0945e6c57d2fa1e5ace303fae6f74a" dependencies = [ "alloy-chains", "alloy-consensus", @@ -332,7 +349,7 @@ dependencies = [ "schnellru", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", "url", @@ -341,9 +358,9 @@ dependencies = [ [[package]] name = "alloy-pubsub" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90f1f34232f77341076541c405482e4ae12f0ee7153d8f9969fc1691201b2247" +checksum = "808719714bfb2aa24b0eb2a38411ce8e654ba11c0ebf2a6648fcbe9fabfe696d" dependencies = [ "alloy-json-rpc", "alloy-primitives", @@ -382,9 +399,9 @@ dependencies = [ [[package]] name = "alloy-rpc-client" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "374dbe0dc3abdc2c964f36b3d3edf9cdb3db29d16bda34aa123f03d810bec1dd" +checksum = "6ce26c25efb8290b6ba559ae6c40bf6630d337e107ae242e5790501420dba7b7" dependencies = [ "alloy-json-rpc", "alloy-primitives", @@ -407,9 +424,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c74832aa474b670309c20fffc2a869fa141edab7c79ff7963fad0a08de60bae1" +checksum = "41080ce2640928f0df45c41d2af629b88db3cb31af3abbe614964ae10001ddac" dependencies = [ "alloy-primitives", "alloy-rpc-types-engine", @@ -420,9 +437,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types-admin" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6bfd9b2cc3a1985f1f6da5afc41120256f9f9316fcd89e054cea99dbb10172f6" +checksum = "db981579da4d597d9d35f56ad7641b929bf8f551ab696715132f554863c83540" dependencies = [ "alloy-genesis", "alloy-primitives", @@ -432,9 +449,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types-anvil" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5ca97963132f78ddfc60e43a017348e6d52eea983925c23652f5b330e8e02291" +checksum = "252b7433e731e5d24f7eb7a54a368bc813a1086aaf84643ab10e99599a6ff16c" dependencies = [ "alloy-primitives", "alloy-rpc-types-eth", @@ -442,25 +459,37 @@ dependencies = [ "serde", ] +[[package]] +name = "alloy-rpc-types-any" +version = "0.7.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "abca110e59f760259e26d0c84912121468008aba48dd227af0f306cfd7bce9ae" +dependencies = [ + "alloy-consensus-any", + "alloy-rpc-types-eth", + "alloy-serde", +] + [[package]] name = "alloy-rpc-types-beacon" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "922fa76678d2f9f07ea1b19309b5cfbf244c6029dcba3515227b515fdd6ed4a7" +checksum = "45c8db5fb70d2fece7bc1cd5adf42e72fc8a23547adeff8f558d9063f1e7788c" dependencies = [ "alloy-eips", "alloy-primitives", "alloy-rpc-types-engine", + "alloy-serde", "serde", "serde_with", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "alloy-rpc-types-debug" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba2253bee958658ebd614c07a61c40580e09dd1fad3f017684314442332ab753" +checksum = "ea3a662ced0bfbe582d26ed85d6a0092310787331555c8f7a86f843c7ca272ef" dependencies = [ "alloy-primitives", "serde", @@ -468,9 +497,9 @@ dependencies = [ [[package]] name = "alloy-rpc-types-engine" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3f56294dce86af23ad6ee8df46cf8b0d292eb5d1ff67dc88a0886051e32b1faf" +checksum = "d3b000c7f3469e7faa575ba70207294cf07e91dfd6ce4d04d5d5d8069f974a66" dependencies = [ "alloy-consensus", "alloy-eips", @@ -487,11 +516,12 @@ dependencies = [ [[package]] name = "alloy-rpc-types-eth" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a477281940d82d29315846c7216db45b15e90bcd52309da9f54bcf7ad94a11" +checksum = "3468e7385fbb86b0fde5497d685c02f765ea09d36f7e07c5d1c9a52b077d38e2" dependencies = [ "alloy-consensus", + "alloy-consensus-any", "alloy-eips", "alloy-network-primitives", "alloy-primitives", @@ -508,12 +538,13 @@ dependencies = [ [[package]] name = "alloy-rpc-types-mev" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8647f8135ee3d5de1cf196706c905c05728a4e38bb4a5b61a7214bd1ba8f60a6" +checksum = "26988fb56d87414c96b8fd9b69ad6ce3768bc9acc953ed02c18a66f74ab98c66" dependencies = [ "alloy-eips", "alloy-primitives", + "alloy-rpc-types-eth", "alloy-serde", "serde", "serde_json", @@ -521,23 +552,23 @@ dependencies = [ [[package]] name = "alloy-rpc-types-trace" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecd8b4877ef520c138af702097477cdd19504a8e1e4675ba37e92ba40f2d3c6f" +checksum = "7a90be1bc8e3659db1c9512191873a268a917efbc62b8bd39a92c12bf613b193" dependencies = [ "alloy-primitives", "alloy-rpc-types-eth", "alloy-serde", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "alloy-rpc-types-txpool" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d4ab49acf90a71f7fb894dc5fd485f1f07a1e348966c714c4d1e0b7478850a8" +checksum = "beade2858d292442f5be6fce452c923072a7ac4d3898d333abf42703945444d0" dependencies = [ "alloy-primitives", "alloy-rpc-types-eth", @@ -547,9 +578,9 @@ dependencies = [ [[package]] name = "alloy-serde" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4dfa4a7ccf15b2492bb68088692481fd6b2604ccbee1d0d6c44c21427ae4df83" +checksum = "42de6002e2154b50b3568aea27e26bd9caf7b754658f43065f2e9b6ee0a8c839" dependencies = [ "alloy-primitives", "arbitrary", @@ -559,23 +590,23 @@ dependencies = [ [[package]] name = "alloy-signer" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e10aec39d60dc27edcac447302c7803d2371946fb737245320a05b78eb2fafd" +checksum = "f288a9a25e2578dab17845fd8d2be1d32de33565783ed185ded161a65f92381b" dependencies = [ "alloy-primitives", "async-trait", "auto_impl", "elliptic-curve", "k256", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "alloy-signer-local" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d8396f6dff60700bc1d215ee03d86ff56de268af96e2bf833a14d0bafcab9882" +checksum = "0d8081f589ddc11a959605e30c723d51cad2562d9072305f8e3ef311f077e5eb" dependencies = [ "alloy-consensus", "alloy-network", @@ -584,7 +615,7 @@ dependencies = [ "async-trait", "k256", "rand", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] @@ -659,9 +690,9 @@ dependencies = [ [[package]] name = "alloy-transport" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f99acddb34000d104961897dbb0240298e8b775a7efffb9fda2a1a3efedd65b3" +checksum = "90352f4cf78017905c3244f48b38fadc345970bbc9095087c0f985a580550488" dependencies = [ "alloy-json-rpc", "base64 0.22.1", @@ -669,7 +700,7 @@ dependencies = [ "futures-utils-wasm", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tower 0.5.1", "tracing", @@ -679,9 +710,9 @@ dependencies = [ [[package]] name = "alloy-transport-http" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dc013132e34eeadaa0add7e74164c1503988bfba8bae885b32e0918ba85a8a6" +checksum = "7d26c94d51fa8b1aee3d15db113dd0773776c02bb36dbaa2590b900dadd7e7d0" dependencies = [ "alloy-json-rpc", "alloy-transport", @@ -694,9 +725,9 @@ dependencies = [ [[package]] name = "alloy-transport-ws" -version = "0.6.4" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abd170e600801116d5efe64f74a4fc073dbbb35c807013a7d0a388742aeebba0" +checksum = "cd7b21335b55c9f715e2acca0228dc1d6880d961756916c13a9ce70f9f413e70" dependencies = [ "alloy-pubsub", "alloy-transport", @@ -4159,6 +4190,16 @@ dependencies = [ "winapi", ] +[[package]] +name = "nu-ansi-term" +version = "0.46.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" +dependencies = [ + "overload", + "winapi", +] + [[package]] name = "num" version = "0.4.3" @@ -4315,9 +4356,9 @@ dependencies = [ [[package]] name = "op-alloy-consensus" -version = "0.6.8" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fce158d886815d419222daa67fcdf949a34f7950653a4498ebeb4963331f70ed" +checksum = "77284451ec70602f148f4f3bc6d1106fdfefd57c11ff459c4b2985e400ed1a18" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4328,14 +4369,14 @@ dependencies = [ "derive_more", "serde", "serde_with", - "thiserror 2.0.3", + "thiserror 2.0.4", ] [[package]] name = "op-alloy-rpc-types" -version = "0.6.8" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "060ebeaea8c772e396215f69bb86d231ec8b7f36aca0dd6ce367ceaa9a8c33e6" +checksum = "2bdc32eba4d43bbd23f1f16dece7afd991d41ab4ffc2494a72b048e9f38db622" dependencies = [ "alloy-consensus", "alloy-eips", @@ -4368,6 +4409,12 @@ version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "04744f49eae99ab78e0d5c0b603ab218f515ea8cfe5a456d7629ad883a3b6e7d" +[[package]] +name = "overload" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" + [[package]] name = "page_size" version = "0.6.0" @@ -4803,7 +4850,7 @@ dependencies = [ "rustc-hash 2.1.0", "rustls", "socket2", - "thiserror 2.0.3", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -4822,7 +4869,7 @@ dependencies = [ "rustls", "rustls-pki-types", "slab", - "thiserror 2.0.3", + "thiserror 2.0.4", "tinyvec", "tracing", "web-time", @@ -5082,7 +5129,7 @@ dependencies = [ [[package]] name = "reth" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5155,7 +5202,7 @@ dependencies = [ [[package]] name = "reth-basic-payload-builder" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5184,7 +5231,7 @@ dependencies = [ [[package]] name = "reth-beacon-consensus" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5194,6 +5241,8 @@ dependencies = [ "itertools 0.13.0", "metrics", "reth-blockchain-tree-api", + "reth-codecs", + "reth-db-api", "reth-engine-primitives", "reth-errors", "reth-ethereum-consensus", @@ -5205,6 +5254,7 @@ dependencies = [ "reth-payload-primitives", "reth-payload-validator", "reth-primitives", + "reth-primitives-traits", "reth-provider", "reth-prune", "reth-stages-api", @@ -5212,7 +5262,7 @@ dependencies = [ "reth-tasks", "reth-tokio-util", "schnellru", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tracing", @@ -5221,7 +5271,7 @@ dependencies = [ [[package]] name = "reth-blockchain-tree" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -5254,7 +5304,7 @@ dependencies = [ [[package]] name = "reth-blockchain-tree-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -5262,20 +5312,19 @@ dependencies = [ "reth-execution-errors", "reth-primitives", "reth-storage-errors", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-chain-state" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", "alloy-primitives", "alloy-signer", "alloy-signer-local", - "auto_impl", "derive_more", "metrics", "parking_lot", @@ -5286,6 +5335,7 @@ dependencies = [ "reth-execution-types", "reth-metrics", "reth-primitives", + "reth-primitives-traits", "reth-storage-api", "reth-trie", "revm", @@ -5297,7 +5347,7 @@ dependencies = [ [[package]] name = "reth-chainspec" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-chains", "alloy-consensus", @@ -5317,7 +5367,7 @@ dependencies = [ [[package]] name = "reth-cli" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-genesis", "clap", @@ -5331,7 +5381,7 @@ dependencies = [ [[package]] name = "reth-cli-commands" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "ahash", "alloy-consensus", @@ -5353,6 +5403,7 @@ dependencies = [ "reth-cli", "reth-cli-runner", "reth-cli-util", + "reth-codecs", "reth-config", "reth-consensus", "reth-db", @@ -5368,6 +5419,7 @@ dependencies = [ "reth-network", "reth-network-p2p", "reth-network-peers", + "reth-node-api", "reth-node-builder", "reth-node-core", "reth-node-events", @@ -5391,7 +5443,7 @@ dependencies = [ [[package]] name = "reth-cli-runner" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "reth-tasks", "tokio", @@ -5401,7 +5453,7 @@ dependencies = [ [[package]] name = "reth-cli-util" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -5412,14 +5464,14 @@ dependencies = [ "reth-fs-util", "secp256k1", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tikv-jemallocator", ] [[package]] name = "reth-codecs" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5438,7 +5490,7 @@ dependencies = [ [[package]] name = "reth-codecs-derive" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "convert_case", "proc-macro2", @@ -5449,7 +5501,7 @@ dependencies = [ [[package]] name = "reth-config" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "eyre", "humantime-serde", @@ -5463,7 +5515,7 @@ dependencies = [ [[package]] name = "reth-consensus" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5477,7 +5529,7 @@ dependencies = [ [[package]] name = "reth-consensus-common" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5485,13 +5537,14 @@ dependencies = [ "reth-chainspec", "reth-consensus", "reth-primitives", + "reth-primitives-traits", "revm-primitives", ] [[package]] name = "reth-consensus-debug-client" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5515,7 +5568,7 @@ dependencies = [ [[package]] name = "reth-db" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -5525,7 +5578,6 @@ dependencies = [ "metrics", "page_size", "parking_lot", - "paste", "reth-db-api", "reth-fs-util", "reth-libmdbx", @@ -5543,13 +5595,13 @@ dependencies = [ "strum", "sysinfo", "tempfile", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-db-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-genesis", @@ -5569,14 +5621,16 @@ dependencies = [ "reth-stages-types", "reth-storage-errors", "reth-trie-common", + "roaring", "serde", ] [[package]] name = "reth-db-common" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", "alloy-genesis", "alloy-primitives", "boyer-moore-magiclen", @@ -5596,14 +5650,14 @@ dependencies = [ "reth-trie-db", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tracing", ] [[package]] name = "reth-db-models" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -5619,7 +5673,7 @@ dependencies = [ [[package]] name = "reth-discv4" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -5636,7 +5690,7 @@ dependencies = [ "schnellru", "secp256k1", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tracing", @@ -5645,7 +5699,7 @@ dependencies = [ [[package]] name = "reth-discv5" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -5661,7 +5715,7 @@ dependencies = [ "reth-metrics", "reth-network-peers", "secp256k1", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -5669,7 +5723,7 @@ dependencies = [ [[package]] name = "reth-dns-discovery" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "data-encoding", @@ -5683,7 +5737,7 @@ dependencies = [ "secp256k1", "serde", "serde_with", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tracing", @@ -5693,7 +5747,7 @@ dependencies = [ [[package]] name = "reth-downloaders" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5714,7 +5768,7 @@ dependencies = [ "reth-primitives-traits", "reth-storage-api", "reth-tasks", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tokio-util", @@ -5724,7 +5778,7 @@ dependencies = [ [[package]] name = "reth-ecies" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "aes", "alloy-primitives", @@ -5744,7 +5798,7 @@ dependencies = [ "secp256k1", "sha2 0.10.8", "sha3", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tokio-util", @@ -5755,8 +5809,9 @@ dependencies = [ [[package]] name = "reth-engine-local" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", "alloy-primitives", "alloy-rpc-types-engine", "eyre", @@ -5769,10 +5824,10 @@ dependencies = [ "reth-engine-tree", "reth-ethereum-engine-primitives", "reth-evm", + "reth-node-types", "reth-payload-builder", "reth-payload-builder-primitives", "reth-payload-primitives", - "reth-payload-validator", "reth-provider", "reth-prune", "reth-rpc-types-compat", @@ -5786,8 +5841,9 @@ dependencies = [ [[package]] name = "reth-engine-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", "alloy-primitives", "alloy-rpc-types-engine", "futures", @@ -5796,16 +5852,17 @@ dependencies = [ "reth-payload-builder-primitives", "reth-payload-primitives", "reth-primitives", + "reth-primitives-traits", "reth-trie", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", ] [[package]] name = "reth-engine-service" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "futures", "pin-project", @@ -5818,30 +5875,30 @@ dependencies = [ "reth-network-p2p", "reth-node-types", "reth-payload-builder", - "reth-payload-validator", "reth-provider", "reth-prune", "reth-stages-api", "reth-tasks", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-engine-tree" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", "alloy-primitives", + "alloy-rlp", "alloy-rpc-types-engine", "futures", "metrics", + "rayon", "reth-beacon-consensus", "reth-blockchain-tree", "reth-blockchain-tree-api", "reth-chain-state", - "reth-chainspec", "reth-consensus", "reth-engine-primitives", "reth-errors", @@ -5851,7 +5908,6 @@ dependencies = [ "reth-payload-builder", "reth-payload-builder-primitives", "reth-payload-primitives", - "reth-payload-validator", "reth-primitives", "reth-provider", "reth-prune", @@ -5859,9 +5915,11 @@ dependencies = [ "reth-stages-api", "reth-tasks", "reth-trie", + "reth-trie-db", "reth-trie-parallel", + "reth-trie-sparse", "revm-primitives", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -5869,7 +5927,7 @@ dependencies = [ [[package]] name = "reth-engine-util" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5879,6 +5937,7 @@ dependencies = [ "futures", "itertools 0.13.0", "pin-project", + "reth-consensus-common", "reth-engine-primitives", "reth-errors", "reth-ethereum-forks", @@ -5901,20 +5960,20 @@ dependencies = [ [[package]] name = "reth-errors" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "reth-blockchain-tree-api", "reth-consensus", "reth-execution-errors", "reth-fs-util", "reth-storage-errors", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-eth-wire" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-chains", "alloy-primitives", @@ -5932,7 +5991,7 @@ dependencies = [ "reth-primitives-traits", "serde", "snap", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tokio-util", @@ -5942,7 +6001,7 @@ dependencies = [ [[package]] name = "reth-eth-wire-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-chains", "alloy-consensus", @@ -5953,16 +6012,17 @@ dependencies = [ "derive_more", "reth-chainspec", "reth-codecs-derive", + "reth-ethereum-forks", "reth-primitives", "reth-primitives-traits", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-ethereum-cli" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "eyre", "reth-chainspec", @@ -5972,7 +6032,7 @@ dependencies = [ [[package]] name = "reth-ethereum-consensus" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -5988,7 +6048,7 @@ dependencies = [ [[package]] name = "reth-ethereum-engine-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -5998,6 +6058,7 @@ dependencies = [ "reth-chainspec", "reth-engine-primitives", "reth-payload-primitives", + "reth-payload-validator", "reth-primitives", "reth-rpc-types-compat", "serde", @@ -6007,7 +6068,7 @@ dependencies = [ [[package]] name = "reth-ethereum-forks" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-chains", "alloy-primitives", @@ -6021,13 +6082,13 @@ dependencies = [ "proptest-derive", "rustc-hash 2.1.0", "serde", - "thiserror-no-std", + "thiserror 2.0.4", ] [[package]] name = "reth-ethereum-payload-builder" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6054,7 +6115,7 @@ dependencies = [ [[package]] name = "reth-etl" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "rayon", "reth-db-api", @@ -6064,7 +6125,7 @@ dependencies = [ [[package]] name = "reth-evm" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6091,7 +6152,7 @@ dependencies = [ [[package]] name = "reth-evm-ethereum" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6110,30 +6171,32 @@ dependencies = [ [[package]] name = "reth-execution-errors" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", "alloy-rlp", - "derive_more", "nybbles", "reth-consensus", "reth-prune-types", "reth-storage-errors", "revm-primitives", + "thiserror 2.0.4", ] [[package]] name = "reth-execution-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", "alloy-eips", "alloy-primitives", "reth-execution-errors", "reth-primitives", "reth-primitives-traits", "reth-trie", + "reth-trie-common", "revm", "serde", "serde_with", @@ -6142,8 +6205,9 @@ dependencies = [ [[package]] name = "reth-exex" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", "alloy-eips", "alloy-primitives", "eyre", @@ -6177,12 +6241,14 @@ dependencies = [ [[package]] name = "reth-exex-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", "reth-chain-state", "reth-execution-types", + "reth-primitives", + "reth-primitives-traits", "serde", "serde_with", ] @@ -6190,17 +6256,17 @@ dependencies = [ [[package]] name = "reth-fs-util" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-invalid-block-hooks" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -6214,6 +6280,7 @@ dependencies = [ "reth-engine-primitives", "reth-evm", "reth-primitives", + "reth-primitives-traits", "reth-provider", "reth-revm", "reth-rpc-api", @@ -6226,7 +6293,7 @@ dependencies = [ [[package]] name = "reth-ipc" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "async-trait", "bytes", @@ -6236,7 +6303,7 @@ dependencies = [ "jsonrpsee", "pin-project", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tokio-util", @@ -6247,7 +6314,7 @@ dependencies = [ [[package]] name = "reth-libmdbx" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "bitflags 2.6.0", "byteorder", @@ -6257,14 +6324,14 @@ dependencies = [ "parking_lot", "reth-mdbx-sys", "smallvec", - "thiserror 1.0.69", + "thiserror 2.0.4", "tracing", ] [[package]] name = "reth-mdbx-sys" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "bindgen", "cc", @@ -6273,7 +6340,7 @@ dependencies = [ [[package]] name = "reth-metrics" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "futures", "metrics", @@ -6285,7 +6352,7 @@ dependencies = [ [[package]] name = "reth-net-banlist" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", ] @@ -6293,13 +6360,13 @@ dependencies = [ [[package]] name = "reth-net-nat" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "futures-util", "if-addrs", "reqwest", "serde_with", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -6307,7 +6374,7 @@ dependencies = [ [[package]] name = "reth-network" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6332,6 +6399,7 @@ dependencies = [ "reth-ecies", "reth-eth-wire", "reth-eth-wire-types", + "reth-ethereum-forks", "reth-fs-util", "reth-metrics", "reth-net-banlist", @@ -6351,7 +6419,7 @@ dependencies = [ "secp256k1", "serde", "smallvec", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tokio-util", @@ -6361,7 +6429,7 @@ dependencies = [ [[package]] name = "reth-network-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rpc-types-admin", @@ -6376,7 +6444,7 @@ dependencies = [ "reth-network-types", "reth-tokio-util", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", ] @@ -6384,7 +6452,7 @@ dependencies = [ [[package]] name = "reth-network-p2p" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6407,14 +6475,14 @@ dependencies = [ [[package]] name = "reth-network-peers" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rlp", "enr", "secp256k1", "serde_with", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "url", ] @@ -6422,7 +6490,7 @@ dependencies = [ [[package]] name = "reth-network-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "humantime-serde", "reth-ethereum-forks", @@ -6436,7 +6504,7 @@ dependencies = [ [[package]] name = "reth-nippy-jar" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "anyhow", "bincode", @@ -6445,7 +6513,7 @@ dependencies = [ "memmap2", "reth-fs-util", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tracing", "zstd", ] @@ -6453,7 +6521,7 @@ dependencies = [ [[package]] name = "reth-node-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-rpc-types-engine", @@ -6475,7 +6543,7 @@ dependencies = [ [[package]] name = "reth-node-builder" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -6539,7 +6607,7 @@ dependencies = [ [[package]] name = "reth-node-core" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6560,6 +6628,7 @@ dependencies = [ "reth-db", "reth-discv4", "reth-discv5", + "reth-ethereum-forks", "reth-net-nat", "reth-network", "reth-network-p2p", @@ -6579,7 +6648,7 @@ dependencies = [ "serde", "shellexpand", "strum", - "thiserror 1.0.69", + "thiserror 2.0.4", "toml", "tracing", "vergen", @@ -6588,7 +6657,7 @@ dependencies = [ [[package]] name = "reth-node-ethereum" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "eyre", @@ -6617,7 +6686,7 @@ dependencies = [ [[package]] name = "reth-node-events" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6630,7 +6699,7 @@ dependencies = [ "reth-engine-primitives", "reth-network-api", "reth-primitives-traits", - "reth-prune", + "reth-prune-types", "reth-stages", "reth-static-file-types", "reth-storage-api", @@ -6641,20 +6710,17 @@ dependencies = [ [[package]] name = "reth-node-metrics" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "eyre", "http", - "jsonrpsee", + "jsonrpsee-server", "metrics", "metrics-exporter-prometheus", "metrics-process", "metrics-util", "procfs 0.16.0", - "reth-db-api", "reth-metrics", - "reth-primitives-traits", - "reth-provider", "reth-tasks", "tikv-jemalloc-ctl", "tokio", @@ -6666,7 +6732,7 @@ dependencies = [ [[package]] name = "reth-node-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "reth-chainspec", "reth-db-api", @@ -6678,25 +6744,29 @@ dependencies = [ [[package]] name = "reth-optimism-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", "alloy-primitives", "alloy-rlp", + "arbitrary", "bytes", "derive_more", "op-alloy-consensus", + "rand", "reth-codecs", "reth-primitives", "reth-primitives-traits", + "revm-primitives", + "secp256k1", "serde", ] [[package]] name = "reth-payload-builder" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-rpc-types", "async-trait", @@ -6715,7 +6785,7 @@ dependencies = [ [[package]] name = "reth-payload-builder-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-rpc-types-engine", "async-trait", @@ -6729,7 +6799,7 @@ dependencies = [ [[package]] name = "reth-payload-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -6740,14 +6810,14 @@ dependencies = [ "reth-primitives", "revm-primitives", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", ] [[package]] name = "reth-payload-util" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -6757,7 +6827,7 @@ dependencies = [ [[package]] name = "reth-payload-validator" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-rpc-types", "reth-chainspec", @@ -6768,7 +6838,7 @@ dependencies = [ [[package]] name = "reth-primitives" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6803,7 +6873,7 @@ dependencies = [ [[package]] name = "reth-primitives-traits" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6816,11 +6886,11 @@ dependencies = [ "bytes", "derive_more", "modular-bitfield", + "op-alloy-consensus", "proptest", "proptest-arbitrary-interop", "reth-codecs", "revm-primitives", - "roaring", "serde", "serde_with", ] @@ -6828,7 +6898,7 @@ dependencies = [ [[package]] name = "reth-provider" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -6858,6 +6928,7 @@ dependencies = [ "reth-node-types", "reth-optimism-primitives", "reth-primitives", + "reth-primitives-traits", "reth-prune-types", "reth-stages-types", "reth-storage-api", @@ -6873,8 +6944,10 @@ dependencies = [ [[package]] name = "reth-prune" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ + "alloy-consensus", + "alloy-eips", "alloy-primitives", "itertools 0.13.0", "metrics", @@ -6886,12 +6959,13 @@ dependencies = [ "reth-errors", "reth-exex-types", "reth-metrics", + "reth-primitives-traits", "reth-provider", "reth-prune-types", "reth-static-file-types", "reth-tokio-util", "rustc-hash 2.1.0", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -6899,7 +6973,7 @@ dependencies = [ [[package]] name = "reth-prune-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "arbitrary", @@ -6908,13 +6982,13 @@ dependencies = [ "modular-bitfield", "reth-codecs", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", ] [[package]] name = "reth-revm" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -6931,7 +7005,7 @@ dependencies = [ [[package]] name = "reth-rpc" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-dyn-abi", @@ -6974,6 +7048,7 @@ dependencies = [ "reth-network-types", "reth-payload-validator", "reth-primitives", + "reth-primitives-traits", "reth-provider", "reth-revm", "reth-rpc-api", @@ -6990,7 +7065,7 @@ dependencies = [ "revm-primitives", "serde", "serde_json", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tower 0.4.13", @@ -7001,7 +7076,7 @@ dependencies = [ [[package]] name = "reth-rpc-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-json-rpc", @@ -7026,7 +7101,7 @@ dependencies = [ [[package]] name = "reth-rpc-builder" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "http", @@ -7041,6 +7116,7 @@ dependencies = [ "reth-metrics", "reth-network-api", "reth-node-core", + "reth-primitives", "reth-provider", "reth-rpc", "reth-rpc-api", @@ -7051,7 +7127,7 @@ dependencies = [ "reth-tasks", "reth-transaction-pool", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-util", "tower 0.4.13", @@ -7062,7 +7138,7 @@ dependencies = [ [[package]] name = "reth-rpc-engine-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -7087,7 +7163,7 @@ dependencies = [ "reth-tasks", "reth-transaction-pool", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -7095,7 +7171,7 @@ dependencies = [ [[package]] name = "reth-rpc-eth-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-dyn-abi", @@ -7128,6 +7204,7 @@ dependencies = [ "reth-tasks", "reth-transaction-pool", "reth-trie", + "reth-trie-common", "revm", "revm-inspectors", "revm-primitives", @@ -7138,7 +7215,7 @@ dependencies = [ [[package]] name = "reth-rpc-eth-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -7155,10 +7232,10 @@ dependencies = [ "reth-chain-state", "reth-chainspec", "reth-errors", - "reth-evm", "reth-execution-types", "reth-metrics", "reth-primitives", + "reth-primitives-traits", "reth-revm", "reth-rpc-server-types", "reth-rpc-types-compat", @@ -7171,7 +7248,7 @@ dependencies = [ "revm-primitives", "schnellru", "serde", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tracing", @@ -7180,7 +7257,7 @@ dependencies = [ [[package]] name = "reth-rpc-layer" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-rpc-types-engine", "http", @@ -7194,7 +7271,7 @@ dependencies = [ [[package]] name = "reth-rpc-server-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", @@ -7210,7 +7287,7 @@ dependencies = [ [[package]] name = "reth-rpc-types-compat" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -7218,19 +7295,18 @@ dependencies = [ "alloy-rlp", "alloy-rpc-types-engine", "alloy-rpc-types-eth", - "alloy-serde", "jsonrpsee-types", "reth-primitives", - "reth-trie-common", "serde", ] [[package]] name = "reth-stages" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", + "alloy-eips", "alloy-primitives", "bincode", "futures-util", @@ -7257,7 +7333,7 @@ dependencies = [ "reth-storage-errors", "reth-trie", "reth-trie-db", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -7265,7 +7341,7 @@ dependencies = [ [[package]] name = "reth-stages-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "aquamarine", @@ -7283,7 +7359,7 @@ dependencies = [ "reth-static-file", "reth-static-file-types", "reth-tokio-util", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", ] @@ -7291,7 +7367,7 @@ dependencies = [ [[package]] name = "reth-stages-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "arbitrary", @@ -7305,13 +7381,15 @@ dependencies = [ [[package]] name = "reth-static-file" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "parking_lot", "rayon", + "reth-codecs", "reth-db", "reth-db-api", + "reth-primitives-traits", "reth-provider", "reth-prune-types", "reth-stages-types", @@ -7324,7 +7402,7 @@ dependencies = [ [[package]] name = "reth-static-file-types" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "clap", @@ -7336,7 +7414,7 @@ dependencies = [ [[package]] name = "reth-storage-api" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -7349,29 +7427,32 @@ dependencies = [ "reth-db-models", "reth-execution-types", "reth-primitives", + "reth-primitives-traits", "reth-prune-types", "reth-stages-types", "reth-storage-errors", "reth-trie", + "reth-trie-db", ] [[package]] name = "reth-storage-errors" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-eips", "alloy-primitives", "alloy-rlp", "derive_more", "reth-fs-util", - "reth-primitives", + "reth-primitives-traits", + "reth-static-file-types", ] [[package]] name = "reth-tasks" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "auto_impl", "dyn-clone", @@ -7380,7 +7461,7 @@ dependencies = [ "pin-project", "rayon", "reth-metrics", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tracing", "tracing-futures", @@ -7389,7 +7470,7 @@ dependencies = [ [[package]] name = "reth-tokio-util" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "tokio", "tokio-stream", @@ -7399,7 +7480,7 @@ dependencies = [ [[package]] name = "reth-tracing" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "clap", "eyre", @@ -7414,7 +7495,7 @@ dependencies = [ [[package]] name = "reth-transaction-pool" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-eips", @@ -7443,7 +7524,7 @@ dependencies = [ "schnellru", "serde", "smallvec", - "thiserror 1.0.69", + "thiserror 2.0.4", "tokio", "tokio-stream", "tracing", @@ -7452,7 +7533,7 @@ dependencies = [ [[package]] name = "reth-trie" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-primitives", @@ -7468,9 +7549,8 @@ dependencies = [ "reth-stages-types", "reth-storage-errors", "reth-trie-common", + "reth-trie-sparse", "revm", - "serde", - "serde_with", "tracing", "triehash", ] @@ -7478,12 +7558,14 @@ dependencies = [ [[package]] name = "reth-trie-common" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-consensus", "alloy-genesis", "alloy-primitives", "alloy-rlp", + "alloy-rpc-types-eth", + "alloy-serde", "alloy-trie", "arbitrary", "bytes", @@ -7496,12 +7578,13 @@ dependencies = [ "reth-primitives-traits", "revm-primitives", "serde", + "serde_with", ] [[package]] name = "reth-trie-db" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -7514,7 +7597,6 @@ dependencies = [ "reth-primitives", "reth-storage-errors", "reth-trie", - "reth-trie-common", "revm", "serde", "tracing", @@ -7524,7 +7606,7 @@ dependencies = [ [[package]] name = "reth-trie-parallel" version = "1.1.2" -source = "git+https://github.com/paradigmxyz/reth?rev=496bf0bf715f0a1fafc198f8d72ccd71913d1a40#496bf0bf715f0a1fafc198f8d72ccd71913d1a40" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" dependencies = [ "alloy-primitives", "alloy-rlp", @@ -7540,10 +7622,24 @@ dependencies = [ "reth-trie", "reth-trie-common", "reth-trie-db", - "thiserror 1.0.69", + "thiserror 2.0.4", "tracing", ] +[[package]] +name = "reth-trie-sparse" +version = "1.1.2" +source = "git+https://github.com/paradigmxyz/reth?rev=8f61af0136e1a20119832925081c341ae89b93f0#8f61af0136e1a20119832925081c341ae89b93f0" +dependencies = [ + "alloy-primitives", + "alloy-rlp", + "reth-primitives-traits", + "reth-tracing", + "reth-trie-common", + "smallvec", + "thiserror 2.0.4", +] + [[package]] name = "reth_gnosis" version = "0.1.0" @@ -7595,7 +7691,7 @@ dependencies = [ "serde", "serde_json", "serde_with", - "thiserror 1.0.69", + "thiserror 2.0.4", "thiserror-no-std", "tikv-jemalloc-ctl", "tikv-jemallocator", @@ -7620,9 +7716,9 @@ dependencies = [ [[package]] name = "revm-inspectors" -version = "0.11.0" +version = "0.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "747291a18ad6726a08dd73f8b6a6b3a844db582ecae2063ccf0a04880c44f482" +checksum = "41bbeb6004cc4ed48d27756f0479011df91a6f5642a3abab9309eda5ce67c4ad" dependencies = [ "alloy-primitives", "alloy-rpc-types-eth", @@ -7775,7 +7871,6 @@ checksum = "f81dc953b2244ddd5e7860cb0bb2a790494b898ef321d4aff8e260efab60cc88" dependencies = [ "bytemuck", "byteorder", - "serde", ] [[package]] @@ -8570,9 +8665,9 @@ dependencies = [ [[package]] name = "sysinfo" -version = "0.31.4" +version = "0.32.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "355dbe4f8799b304b05e1b0f05fc59b2a18d36645cf169607da45bde2f69a1be" +checksum = "4c33cd241af0f2e9e3b5c32163b873b29956890b5342e6745b917ce9d490f4af" dependencies = [ "core-foundation-sys", "libc", @@ -8617,11 +8712,11 @@ dependencies = [ [[package]] name = "thiserror" -version = "2.0.3" +version = "2.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c006c85c7651b3cf2ada4584faa36773bd07bac24acfb39f3c431b36d7e667aa" +checksum = "2f49a1853cf82743e3b7950f77e0f4d622ca36cf4317cba00c767838bac8d490" dependencies = [ - "thiserror-impl 2.0.3", + "thiserror-impl 2.0.4", ] [[package]] @@ -8637,9 +8732,9 @@ dependencies = [ [[package]] name = "thiserror-impl" -version = "2.0.3" +version = "2.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f077553d607adc1caf65430528a576c757a71ed73944b66ebb58ef2bbd243568" +checksum = "8381894bb3efe0c4acac3ded651301ceee58a15d47c2e34885ed1908ad667061" dependencies = [ "proc-macro2", "quote", @@ -9074,6 +9169,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e8189decb5ac0fa7bc8b96b7cb9b2701d60d48805aca84a238004d665fcc4008" dependencies = [ "matchers", + "nu-ansi-term", "once_cell", "regex", "serde", diff --git a/Cargo.toml b/Cargo.toml index acb67e2..d4cbfc2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -12,63 +12,63 @@ name = "reth" path = "src/main.rs" [dependencies] -reth = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-evm = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-engine-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-node-ethereum = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-evm-ethereum = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-ethereum-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-chainspec = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-chain-state = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-cli = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-cli-util = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -# reth-auto-seal-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-prune-types = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-basic-payload-builder = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-ethereum-payload-builder = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-ethereum-engine-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-provider = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40", features = ["test-utils"] } -reth-errors = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-db = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-db-api = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-rpc = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-stages = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-stages-api = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-stages-types = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-trie = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } -reth-trie-db = { git = "https://github.com/paradigmxyz/reth", rev = "496bf0bf715f0a1fafc198f8d72ccd71913d1a40" } +reth = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-evm = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-engine-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-node-ethereum = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-evm-ethereum = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-ethereum-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-chainspec = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-chain-state = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-cli = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-cli-util = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +# reth-auto-seal-consensus = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-prune-types = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-basic-payload-builder = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-ethereum-payload-builder = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-ethereum-engine-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-provider = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0", features = ["test-utils"] } +reth-errors = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-db = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-db-api = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-rpc = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-stages = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-stages-api = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-stages-types = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-primitives = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-trie = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } +reth-trie-db = { git = "https://github.com/paradigmxyz/reth", rev = "8f61af0136e1a20119832925081c341ae89b93f0" } eyre = "0.6" clap = { version = "4.5.6", features = ["derive"] } # revm revm = { version = "18.0.0", features = ["std"], default-features = false } -revm-inspectors = "0.11.0" +revm-inspectors = "0.12.0" revm-primitives = { version = "14.0.0", features = [ "std", ], default-features = false } -serde_json = "1.0.94" serde = { version = "1.0", default-features = false } +serde_json = "1.0.94" serde_with = "3.3.0" hex = "0.4.3" walkdir = "2.3.3" -thiserror = "1.0" +thiserror = { version = "2.0.0", default-features = false } thiserror-no-std = { version = "2.0.2", default-features = false } # eth -alloy-chains = "0.1.32" +alloy-chains = { version = "0.1.32", default-features = false } alloy-dyn-abi = "0.8.11" alloy-primitives = { version = "0.8.11", default-features = false } -alloy-rlp = "0.3.4" +alloy-rlp = { version = "0.3.4", default-features = false } alloy-sol-types = "0.8.11" alloy-trie = { version = "0.7", default-features = false } -alloy-consensus = { version = "0.6.4", default-features = false } -alloy-eips = { version = "0.6.4", default-features = false } +alloy-consensus = { version = "0.7.2", default-features = false } +alloy-eips = { version = "0.7.2", default-features = false } alloy-sol-macro = "0.8.9" -alloy-serde = { version = "0.6.4", default-features = false } +alloy-serde = { version = "0.7.2", default-features = false } rayon = "1.7" tracing = "0.1.0" diff --git a/src/evm_config.rs b/src/evm_config.rs index 6552720..a9a3b6c 100644 --- a/src/evm_config.rs +++ b/src/evm_config.rs @@ -2,10 +2,10 @@ use alloy_consensus::Header; use alloy_primitives::{Address, U256}; use reth::revm::{inspector_handle_register, Database, GetInspector}; use reth::revm::{Evm, EvmBuilder}; -use reth_chainspec::ChainSpec; +use reth_chainspec::{ChainSpec, Head}; use reth_evm::{ConfigureEvm, ConfigureEvmEnv}; use reth_evm_ethereum::{revm_spec, revm_spec_by_timestamp_after_merge}; -use reth_primitives::{transaction::FillTxEnv, Head, TransactionSigned}; +use reth_primitives::{transaction::FillTxEnv, TransactionSigned}; use revm::{ handler::mainnet::reward_beneficiary as reward_beneficiary_mainnet, interpreter::Gas, Context, }; diff --git a/src/execute.rs b/src/execute.rs index f443a74..3383d26 100644 --- a/src/execute.rs +++ b/src/execute.rs @@ -9,6 +9,9 @@ use alloy_primitives::Address; use core::fmt::Display; use reth_chainspec::ChainSpec; use reth_chainspec::EthereumHardforks; +use reth_errors::ConsensusError; +use reth_ethereum_consensus::validate_block_post_execution; +use reth_evm::system_calls::OnStateHook; use reth_evm::{ execute::{ BlockExecutionError, BlockExecutionStrategy, BlockExecutionStrategyFactory, @@ -19,6 +22,7 @@ use reth_evm::{ }; use reth_evm_ethereum::eip6110::parse_deposits_from_receipts; use reth_node_ethereum::BasicBlockExecutorProvider; +use reth_primitives::EthPrimitives; use reth_primitives::{BlockWithSenders, Receipt}; use revm::State; use revm_primitives::{ @@ -76,6 +80,8 @@ where .build(); GnosisExecutionStrategy::new(state, self.chain_spec.clone(), self.evm_config.clone()) } + + type Primitives = EthPrimitives; } // Block execution strategy for Gnosis @@ -139,13 +145,18 @@ where } } -impl BlockExecutionStrategy for GnosisExecutionStrategy +impl BlockExecutionStrategy for GnosisExecutionStrategy where DB: Database + Display>, EvmConfig: ConfigureEvm
, { + type DB = DB; type Error = BlockExecutionError; + type Primitives = EthPrimitives; + + fn init(&mut self, _tx_env_overrides: Box) {} + fn apply_pre_execution_changes( &mut self, block: &BlockWithSenders, @@ -201,7 +212,7 @@ where error: Box::new(new_err), } })?; - self.system_caller.on_state(&result_and_state); + self.system_caller.on_state(&result_and_state.state); let ResultAndState { result, state } = result_and_state; evm.db_mut().commit(state); @@ -272,6 +283,19 @@ where fn state_mut(&mut self) -> &mut State { &mut self.state } + + fn with_state_hook(&mut self, hook: Option>) { + self.system_caller.with_state_hook(hook); + } + + fn validate_block_post_execution( + &self, + block: &BlockWithSenders, + receipts: &[Receipt], + requests: &Requests, + ) -> Result<(), ConsensusError> { + validate_block_post_execution(block, &self.chain_spec.clone(), receipts, requests) + } } /// Helper type with backwards compatible methods to obtain executor providers. diff --git a/src/lib.rs b/src/lib.rs index 5bbccc3..e075196 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,4 +1,4 @@ -use consensus::GnosisBeaconConsensus; +// use consensus::GnosisBeaconConsensus; use evm_config::GnosisEvmConfig; use execute::GnosisExecutionStrategyFactory; use eyre::eyre; @@ -15,16 +15,18 @@ use reth::{ }; use reth_chainspec::ChainSpec; use reth_engine_primitives::EngineValidator; +use reth_ethereum_consensus::EthBeaconConsensus; use reth_ethereum_engine_primitives::EthereumEngineValidator; use reth_node_ethereum::{ node::{EthereumNetworkBuilder, EthereumPoolBuilder}, BasicBlockExecutorProvider, EthEngineTypes, EthereumNode, }; +use reth_primitives::EthPrimitives; +use reth_provider::EthStorage; use reth_rpc::EthApi; use reth_trie_db::MerklePatriciaTrie; use std::sync::Arc; -mod consensus; mod errors; mod evm_config; pub mod execute; @@ -65,8 +67,18 @@ impl GnosisNode { GnosisConsensusBuilder, > where + // Node: FullNodeTypes>, + // ::Engine: PayloadTypes< + // BuiltPayload = EthBuiltPayload, + // PayloadAttributes = EthPayloadAttributes, + // PayloadBuilderAttributes = EthPayloadBuilderAttributes, + // >, Node: FullNodeTypes< - Types: NodeTypesWithEngine, + Types: NodeTypesWithEngine< + Engine = EthEngineTypes, + ChainSpec = ChainSpec, + Primitives = EthPrimitives, + >, >, { EthereumNode::components::() @@ -81,9 +93,10 @@ impl GnosisNode { /// Configure the node types impl NodeTypes for GnosisNode { - type Primitives = (); + type Primitives = EthPrimitives; type ChainSpec = ChainSpec; type StateCommitment = MerklePatriciaTrie; + type Storage = EthStorage; } impl NodeTypesWithEngine for GnosisNode { @@ -104,7 +117,14 @@ pub type GnosisAddOns = RpcAddOns< impl Node for GnosisNode where - N: FullNodeTypes>, + N: FullNodeTypes< + Types: NodeTypesWithEngine< + Engine = EthEngineTypes, + ChainSpec = ChainSpec, + Primitives = EthPrimitives, + Storage = EthStorage, + >, + >, { type ComponentsBuilder = ComponentsBuilder< N, @@ -136,7 +156,13 @@ pub struct GnosisExecutorBuilder; impl ExecutorBuilder for GnosisExecutorBuilder where - Node: FullNodeTypes>, + Node: FullNodeTypes< + Types: NodeTypesWithEngine< + Engine = EthEngineTypes, + ChainSpec = ChainSpec, + Primitives = EthPrimitives, + >, + >, { // Must implement ConfigureEvm; type EVM = GnosisEvmConfig; @@ -176,12 +202,12 @@ pub struct GnosisConsensusBuilder; impl ConsensusBuilder for GnosisConsensusBuilder where - Node: FullNodeTypes>, + Node: FullNodeTypes>, { - type Consensus = Arc; + type Consensus = Arc; async fn build_consensus(self, ctx: &BuilderContext) -> eyre::Result { - Ok(Arc::new(GnosisBeaconConsensus::new(ctx.chain_spec()))) + Ok(Arc::new(EthBeaconConsensus::new(ctx.chain_spec()))) } } diff --git a/src/payload_builder.rs b/src/payload_builder.rs index 66cf1f7..1e38498 100644 --- a/src/payload_builder.rs +++ b/src/payload_builder.rs @@ -1,7 +1,10 @@ use std::sync::Arc; use alloy_consensus::{Header, EMPTY_OMMER_ROOT_HASH}; -use alloy_eips::{eip4844::MAX_DATA_GAS_PER_BLOCK, eip7685::Requests, merge::BEACON_NONCE}; +use alloy_eips::{ + eip4844::MAX_DATA_GAS_PER_BLOCK, eip7002::WITHDRAWAL_REQUEST_TYPE, + eip7251::CONSOLIDATION_REQUEST_TYPE, eip7685::Requests, merge::BEACON_NONCE, +}; use eyre::eyre; use reth::{ api::{FullNodeTypes, NodeTypesWithEngine}, @@ -10,16 +13,15 @@ use reth::{ EthBuiltPayload, EthPayloadBuilderAttributes, PayloadBuilderError, PayloadBuilderHandle, PayloadBuilderService, }, - primitives::{ - proofs::{self}, - Block, Receipt, - }, revm::database::StateProviderDatabase, - transaction_pool::{noop::NoopTransactionPool, BestTransactionsAttributes, TransactionPool}, + transaction_pool::{ + error::InvalidPoolTransactionError, noop::NoopTransactionPool, BestTransactions, + BestTransactionsAttributes, PoolTransaction, TransactionPool, ValidPoolTransaction, + }, }; use reth_basic_payload_builder::{ - is_better_payload, BasicPayloadJobGenerator, BasicPayloadJobGeneratorConfig, BuildArguments, - BuildOutcome, PayloadBuilder, PayloadConfig, WithdrawalsOutcome, + commit_withdrawals, is_better_payload, BasicPayloadJobGenerator, + BasicPayloadJobGeneratorConfig, BuildArguments, BuildOutcome, PayloadBuilder, PayloadConfig, }; use reth_chain_state::ExecutedBlock; use reth_chainspec::{ChainSpec, EthereumHardforks}; @@ -27,7 +29,10 @@ use reth_errors::RethError; use reth_evm::{system_calls::SystemCaller, ConfigureEvm, ConfigureEvmEnv, NextBlockEnvAttributes}; use reth_evm_ethereum::eip6110::parse_deposits_from_receipts; use reth_node_ethereum::EthEngineTypes; -use reth_primitives::BlockBody; +use reth_primitives::{ + proofs::{self}, + Block, BlockBody, BlockExt, EthPrimitives, InvalidTransactionError, Receipt, TransactionSigned, +}; use reth_provider::{ CanonStateSubscriptions, ChainSpecProvider, ExecutionOutcome, StateProviderFactory, }; @@ -41,6 +46,10 @@ use tracing::{debug, trace, warn}; use crate::{evm_config::GnosisEvmConfig, gnosis::apply_post_block_system_calls}; +type BestTransactionsIter = Box< + dyn BestTransactions::Transaction>>>, +>; + /// A basic Gnosis payload service builder #[derive(Debug, Default, Clone)] pub struct GnosisPayloadServiceBuilder { @@ -56,10 +65,16 @@ impl GnosisPayloadServiceBuilder { impl PayloadServiceBuilder for GnosisPayloadServiceBuilder where - Node: FullNodeTypes>, - ::Provider: reth_provider::StateProviderFactory - + reth_provider::ChainSpecProvider, - Pool: TransactionPool + Unpin + 'static, + Node: FullNodeTypes< + Types: NodeTypesWithEngine< + Engine = EthEngineTypes, + ChainSpec = ChainSpec, + Primitives = EthPrimitives, + >, + >, + Pool: TransactionPool> + + Unpin + + 'static, { async fn spawn_payload_service( self, @@ -162,7 +177,7 @@ impl PayloadBuilder for GnosisPayloadBuil where EvmConfig: ConfigureEvm
, Client: StateProviderFactory + ChainSpecProvider, - Pool: TransactionPool, + Pool: TransactionPool>, { type Attributes = EthPayloadBuilderAttributes; type BuiltPayload = EthBuiltPayload; @@ -174,12 +189,14 @@ where let (cfg_env, block_env) = self .cfg_and_block_env(&args.config, &args.config.parent_header) .map_err(PayloadBuilderError::other)?; + let pool = args.pool.clone(); default_ethereum_payload( self.evm_config.clone(), args, cfg_env, block_env, self.block_rewards_contract, + |attributes| pool.best_transactions_with_attributes(attributes), ) } @@ -199,12 +216,15 @@ where let (cfg_env, block_env) = self .cfg_and_block_env(&args.config, &args.config.parent_header) .map_err(PayloadBuilderError::other)?; + + let pool = args.pool.clone(); default_ethereum_payload( self.evm_config.clone(), args, cfg_env, block_env, self.block_rewards_contract, + |attributes| pool.best_transactions_with_attributes(attributes), )? .into_payload() .ok_or_else(|| PayloadBuilderError::MissingPayload) @@ -220,17 +240,19 @@ where /// and configuration, this function creates a transaction payload. Returns /// a result indicating success with the payload or an error in case of failure. #[inline] -pub fn default_ethereum_payload( +pub fn default_ethereum_payload( evm_config: EvmConfig, args: BuildArguments, initialized_cfg: CfgEnvWithHandlerCfg, initialized_block_env: BlockEnv, block_rewards_contract: Address, + best_txs: F, ) -> Result, PayloadBuilderError> where EvmConfig: ConfigureEvm
, Client: StateProviderFactory + ChainSpecProvider, - Pool: TransactionPool, + Pool: TransactionPool>, + F: FnOnce(BestTransactionsAttributes) -> BestTransactionsIter, { let BuildArguments { client, @@ -244,7 +266,7 @@ where let state_provider = client.state_by_block_hash(config.parent_header.hash())?; let state = StateProviderDatabase::new(state_provider); let mut db = State::builder() - .with_database_ref(cached_reads.as_db(state)) + .with_database(cached_reads.as_db_mut(state)) .with_bundle_update() .build(); let PayloadConfig { @@ -262,13 +284,12 @@ where let mut executed_txs = Vec::new(); let mut executed_senders = Vec::new(); - let mut best_txs = pool.best_transactions_with_attributes(BestTransactionsAttributes::new( + let mut best_txs = best_txs(BestTransactionsAttributes::new( base_fee, initialized_block_env .get_blob_gasprice() .map(|gasprice| gasprice as u64), )); - let mut total_fees = U256::ZERO; let block_number = initialized_block_env.number.to::(); @@ -311,7 +332,10 @@ where // we can't fit this transaction into the block, so we need to mark it as invalid // which also removes all dependent transaction from the iterator before we can // continue - best_txs.mark_invalid(&pool_tx); + best_txs.mark_invalid( + &pool_tx, + InvalidPoolTransactionError::ExceedsGasLimit(pool_tx.gas_limit(), block_gas_limit), + ); continue; } @@ -321,7 +345,7 @@ where } // convert tx to a signed transaction - let tx = pool_tx.to_recovered_transaction(); + let tx = pool_tx.to_consensus(); // There's only limited amount of blob space available per block, so we need to check if // the EIP-4844 can still fit in the block @@ -333,7 +357,13 @@ where // the iterator. This is similar to the gas limit condition // for regular transactions above. trace!(target: "payload_builder", tx=?tx.hash, ?sum_blob_gas_used, ?tx_blob_gas, "skipping blob transaction because it would exceed the max data gas per block"); - best_txs.mark_invalid(&pool_tx); + best_txs.mark_invalid( + &pool_tx, + InvalidPoolTransactionError::ExceedsGasLimit( + tx_blob_gas, + MAX_DATA_GAS_PER_BLOCK, + ), + ); continue; } } @@ -359,7 +389,12 @@ where // if the transaction is invalid, we can skip it and all of its // descendants trace!(target: "payload_builder", %err, ?tx, "skipping invalid transaction and its descendants"); - best_txs.mark_invalid(&pool_tx); + best_txs.mark_invalid( + &pool_tx, + InvalidPoolTransactionError::Consensus( + InvalidTransactionError::TxTypeNotSupported, + ), + ); } continue; @@ -371,10 +406,8 @@ where } } }; - // drop evm so db is released. - drop(evm); // commit changes - db.commit(state); + evm.db_mut().commit(state); // add to the total blob gas used if the transaction successfully executed if let Some(blob_tx) = tx.transaction.as_eip4844() { @@ -441,28 +474,55 @@ where let requests = if chain_spec.is_prague_active_at_timestamp(attributes.timestamp) { let deposit_requests = parse_deposits_from_receipts(&chain_spec, receipts.iter().flatten()) .map_err(|err| PayloadBuilderError::Internal(RethError::Execution(err.into())))?; - Some(Requests::new(vec![deposit_requests])) - } else { - None - }; + let withdrawal_requests = system_caller + .post_block_withdrawal_requests_contract_call( + &mut db, + &initialized_cfg, + &initialized_block_env, + ) + .map_err(|err| PayloadBuilderError::Internal(err.into()))?; + let consolidation_requests = system_caller + .post_block_consolidation_requests_contract_call( + &mut db, + &initialized_cfg, + &initialized_block_env, + ) + .map_err(|err| PayloadBuilderError::Internal(err.into()))?; - let WithdrawalsOutcome { - withdrawals_root, - withdrawals, - } = if !chain_spec.is_shanghai_active_at_timestamp(attributes.timestamp) { - WithdrawalsOutcome::pre_shanghai() - } else if attributes.withdrawals.is_empty() { - WithdrawalsOutcome::empty() - } else { - let withdrawals_root = proofs::calculate_withdrawals_root(&attributes.withdrawals); + let mut requests = Requests::default(); - // calculate withdrawals root - WithdrawalsOutcome { - withdrawals: Some(attributes.withdrawals), - withdrawals_root: Some(withdrawals_root), + if !deposit_requests.is_empty() { + requests.push_request(core::iter::once(0).chain(deposit_requests).collect()); } + + if !withdrawal_requests.is_empty() { + requests.push_request( + core::iter::once(WITHDRAWAL_REQUEST_TYPE) + .chain(withdrawal_requests) + .collect(), + ); + } + + if !consolidation_requests.is_empty() { + requests.push_request( + core::iter::once(CONSOLIDATION_REQUEST_TYPE) + .chain(consolidation_requests) + .collect(), + ); + } + + Some(requests) + } else { + None }; + let withdrawals_root = commit_withdrawals( + &mut db, + &chain_spec, + attributes.timestamp, + &attributes.withdrawals, + )?; + // merge all transitions into bundle state, this would apply the withdrawal balance changes // and 4788 contract call db.merge_transitions(BundleRetention::Reverts); @@ -470,7 +530,7 @@ where let requests_hash = requests.as_ref().map(|requests| requests.requests_hash()); let execution_outcome = ExecutionOutcome::new( db.take_bundle(), - vec![receipts.clone()].into(), + vec![receipts].into(), block_number, vec![requests.clone().unwrap_or_default()], ); @@ -484,9 +544,8 @@ where // calculate the state root let hashed_state = HashedPostState::from_bundle_state(&execution_outcome.state().state); let (state_root, trie_output) = { - let state_provider = db.database.0.inner.borrow_mut(); - state_provider - .db + db.database + .inner() .state_root_with_updates(hashed_state.clone()) .inspect_err(|err| { warn!(target: "payload_builder", @@ -513,7 +572,7 @@ where executed_txs .iter() .filter(|tx| tx.is_eip4844()) - .map(|tx| tx.hash) + .map(|tx| tx.hash()) .collect(), ) .map_err(PayloadBuilderError::other)?; @@ -556,8 +615,13 @@ where blob_gas_used: blob_gas_used.map(Into::into), excess_blob_gas: excess_blob_gas.map(Into::into), requests_hash, + target_blobs_per_block: None, }; + let withdrawals = chain_spec + .is_shanghai_active_at_timestamp(attributes.timestamp) + .then(|| attributes.withdrawals.clone()); + // seal the block let block = Block { header, @@ -569,7 +633,7 @@ where }; let sealed_block = Arc::new(block.seal_slow()); - debug!(target: "payload_builder", ?sealed_block, "sealed built block"); + debug!(target: "payload_builder", id=%attributes.id, sealed_block_header = ?sealed_block.header, "sealed built block"); // create the executed block data let executed = ExecutedBlock { @@ -579,6 +643,7 @@ where hashed_state: Arc::new(hashed_state), trie: Arc::new(trie_output), }; + let mut payload = EthBuiltPayload::new( attributes.id, sealed_block, From 506b5b168d4fe82a7e0597c247d91e3e25e5bd35 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 23:26:33 +0530 Subject: [PATCH 08/10] fix --- src/consensus.rs | 120 ----------------------------------------------- 1 file changed, 120 deletions(-) delete mode 100644 src/consensus.rs diff --git a/src/consensus.rs b/src/consensus.rs deleted file mode 100644 index bd37231..0000000 --- a/src/consensus.rs +++ /dev/null @@ -1,120 +0,0 @@ -use alloy_consensus::Header; -use reth::{ - consensus_common::validation::{ - validate_against_parent_4844, validate_against_parent_eip1559_base_fee, - validate_against_parent_hash_number, validate_body_against_header, validate_cancun_gas, - validate_header_base_fee, validate_header_gas, validate_shanghai_withdrawals, - }, - primitives::{BlockBody, BlockWithSenders, SealedBlock, SealedHeader}, -}; -use reth_chainspec::{ChainSpec, EthereumHardforks}; -use reth_consensus::{Consensus, ConsensusError, PostExecutionInput}; -use reth_primitives::GotExpected; -use revm_primitives::U256; -use std::sync::Arc; - -#[derive(Debug, Clone, PartialEq, Eq)] -pub struct GnosisBeaconConsensus { - /// Configuration - chain_spec: Arc, -} - -impl GnosisBeaconConsensus { - pub fn new(chain_spec: Arc) -> Self { - Self { chain_spec } - } -} - -// `validate_header`, `validate_header_against_parent`, `validate_header_with_total_difficulty`, `validate_block_pre_execution`, `validate_block_post_execution` -impl Consensus for GnosisBeaconConsensus { - fn validate_header(&self, header: &SealedHeader) -> Result<(), ConsensusError> { - validate_header_gas(header)?; - validate_header_base_fee(header, &self.chain_spec) - } - - fn validate_header_against_parent( - &self, - header: &SealedHeader, - parent: &SealedHeader, - ) -> Result<(), ConsensusError> { - validate_against_parent_hash_number(header, parent)?; - validate_against_parent_eip1559_base_fee(header, parent, &self.chain_spec)?; - - // ensure that the blob gas fields for this block - if self - .chain_spec - .is_cancun_active_at_timestamp(header.timestamp) - { - validate_against_parent_4844(header, parent)?; - } - - Ok(()) - } - - fn validate_header_with_total_difficulty( - &self, - _header: &Header, - _total_difficulty: U256, - ) -> Result<(), ConsensusError> { - // TODO - Ok(()) - } - - fn validate_body_against_header( - &self, - body: &BlockBody, - header: &SealedHeader, - ) -> Result<(), ConsensusError> { - validate_body_against_header(body, header) - } - - // fn validate_block_pre_execution(&self, _block: &SealedBlock) -> Result<(), ConsensusError> { - // // TODO - // Ok(()) - // } - - fn validate_block_pre_execution(&self, block: &SealedBlock) -> Result<(), ConsensusError> { - // Check ommers hash - let ommers_hash = reth_primitives::proofs::calculate_ommers_root(&block.body.ommers); - if block.header.ommers_hash != ommers_hash { - return Err(ConsensusError::BodyOmmersHashDiff( - GotExpected { - got: ommers_hash, - expected: block.header.ommers_hash, - } - .into(), - )); - } - - // Check transaction root - if let Err(error) = block.ensure_transaction_root_valid() { - return Err(ConsensusError::BodyTransactionRootDiff(error.into())); - } - - // EIP-4895: Beacon chain push withdrawals as operations - if self - .chain_spec - .is_shanghai_active_at_timestamp(block.timestamp) - { - validate_shanghai_withdrawals(block)?; - } - - if self - .chain_spec - .is_cancun_active_at_timestamp(block.timestamp) - { - validate_cancun_gas(block)?; - } - - Ok(()) - } - - fn validate_block_post_execution( - &self, - _block: &BlockWithSenders, - _input: PostExecutionInput<'_>, - ) -> Result<(), ConsensusError> { - // TODO - Ok(()) - } -} From 5ecad5d72807772908eb1fed4f683be1c2a97ac5 Mon Sep 17 00:00:00 2001 From: debjit Date: Tue, 3 Dec 2024 23:57:40 +0530 Subject: [PATCH 09/10] rebase and bugfixes --- src/testing/cases/blockchain_test.rs | 4 ---- src/testing/models.rs | 3 +++ 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/testing/cases/blockchain_test.rs b/src/testing/cases/blockchain_test.rs index 3ad9d52..eb592b5 100644 --- a/src/testing/cases/blockchain_test.rs +++ b/src/testing/cases/blockchain_test.rs @@ -166,10 +166,6 @@ impl Case for BlockchainTestCase { // Decode and insert blocks, creating a chain of blocks for the test case. let last_block = case.blocks.iter().try_fold(None, |_, block| { let decoded = SealedBlock::decode(&mut block.rlp.as_ref())?; - dbg!( - "printing block during insertion: {:?}", - decoded.clone().try_seal_with_senders().unwrap() - ); provider.insert_historical_block( decoded.clone().try_seal_with_senders().unwrap(), )?; diff --git a/src/testing/models.rs b/src/testing/models.rs index 87dc4aa..76e8863 100644 --- a/src/testing/models.rs +++ b/src/testing/models.rs @@ -88,6 +88,8 @@ pub struct Header { pub parent_beacon_block_root: Option, /// Requests root. pub requests_root: Option, + /// Target blobs per block. + pub target_blobs_per_block: Option, } impl From
for SealedHeader { @@ -114,6 +116,7 @@ impl From
for SealedHeader { excess_blob_gas: value.excess_blob_gas.map(|v| v.to::()), parent_beacon_block_root: value.parent_beacon_block_root, requests_hash: value.requests_root, + target_blobs_per_block: value.target_blobs_per_block.map(|v| v.to::()), }; Self::new(header, value.hash) } From 29dc89372333025c065f5e1ec855699c597f8c34 Mon Sep 17 00:00:00 2001 From: debjit Date: Wed, 4 Dec 2024 13:50:29 +0530 Subject: [PATCH 10/10] feature to exclude time consuming tests (but not enabled) --- src/testing/cases/blockchain_test.rs | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/src/testing/cases/blockchain_test.rs b/src/testing/cases/blockchain_test.rs index eb592b5..8fb21c7 100644 --- a/src/testing/cases/blockchain_test.rs +++ b/src/testing/cases/blockchain_test.rs @@ -234,9 +234,18 @@ impl Case for BlockchainTestCase { /// The reason should be documented in a comment above the file name(s). pub fn should_skip(path: &Path) -> bool { let path_str = path.to_str().expect("Path is not valid UTF-8"); - let name = path.file_name().unwrap().to_str().unwrap(); + let test_name = path.file_name().unwrap().to_str().unwrap(); + let test_folder = path + .parent() + .unwrap() + .file_name() + .unwrap() + .to_str() + .unwrap(); + + // executnig all tests for now false && matches!( - name, + test_name, // funky test with `bigint 0x00` value in json :) not possible to happen on mainnet and require // custom json parser. https://github.com/ethereum/tests/issues/971 | "ValueOverflow.json" @@ -271,6 +280,11 @@ pub fn should_skip(path: &Path) -> bool { | "CALLBlake2f_MaxRounds.json" | "shiftCombinations.json" ) + || matches!( + test_folder, + // These tests are passing, but they take a lot of time to execute + | "stTimeConsuming" + ) // Ignore outdated EOF tests that haven't been updated for Cancun yet. || path_contains(path_str, &["EIPTests", "stEOF"]) }