diff --git a/crates/exex/src/db.rs b/crates/exex/src/db.rs index b857dba17..97fdabc1f 100644 --- a/crates/exex/src/db.rs +++ b/crates/exex/src/db.rs @@ -1,23 +1,16 @@ use reth_primitives::{ revm_primitives::{AccountInfo, Bytecode}, - Address, Bytes, SealedBlockWithSenders, StorageEntry, B256, U256, + Address, SealedBlockWithSenders, B256, U256, }; use reth_provider::OriginalValuesKnown; use reth_revm::db::BundleState; use rusqlite::Connection; use std::{ - collections::HashMap, ops::{Deref, DerefMut}, str::FromStr, sync::{Arc, Mutex, MutexGuard}, }; -/// Types used inside RevertsInit to initialize revms reverts. -pub type AccountRevertInit = (Option>, Vec); - -/// Type used to initialize revms reverts. -pub type RevertsInit = HashMap; - /// A struct representing the database, encapsulating a connection to the SQLite database. /// /// The connection is protected by a `Mutex` for thread-safe access and is shared across @@ -174,17 +167,8 @@ impl reth_revm::Database for Database { self.get_account(address) } - fn code_by_hash(&mut self, code_hash: B256) -> Result { - let bytecode = self.connection().query_row::( - "SELECT data FROM bytecode WHERE hash = ?", - (code_hash.to_string(),), - |row| row.get(0), - ); - match bytecode { - Ok(data) => Ok(Bytecode::new_raw(Bytes::from_str(&data).unwrap())), - Err(rusqlite::Error::QueryReturnedNoRows) => Ok(Bytecode::default()), - Err(err) => Err(err.into()), - } + fn code_by_hash(&mut self, _code_hash: B256) -> Result { + Ok(Default::default()) } fn storage(&mut self, _address: Address, _index: U256) -> Result {