chore: Move consensus trait to standalone crate (#7757)

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
This commit is contained in:
ThreeHrSleep
2024-04-23 17:20:19 +05:30
committed by GitHub
parent 3224837523
commit 6d2e20cd85
66 changed files with 185 additions and 146 deletions

View File

@ -19,6 +19,7 @@ reth-provider.workspace = true
reth-stages-api.workspace = true
reth-trie = { workspace = true, features = ["metrics"] }
reth-trie-parallel = { workspace = true, features = ["parallel"] }
reth-consensus.workspace = true
# common
parking_lot.workspace = true

View File

@ -5,13 +5,13 @@ use crate::{
state::{BlockChainId, TreeState},
AppendableChain, BlockIndices, BlockchainTreeConfig, BundleStateData, TreeExternals,
};
use reth_consensus::{Consensus, ConsensusError};
use reth_db::database::Database;
use reth_interfaces::{
blockchain_tree::{
error::{BlockchainTreeError, CanonicalError, InsertBlockError, InsertBlockErrorKind},
BlockAttachment, BlockStatus, BlockValidationKind, CanonicalOutcome, InsertPayloadOk,
},
consensus::{Consensus, ConsensusError},
executor::{BlockExecutionError, BlockValidationError},
provider::RootMismatch,
RethResult,

View File

@ -5,13 +5,13 @@
use super::externals::TreeExternals;
use crate::BundleStateDataRef;
use reth_consensus::{Consensus, ConsensusError};
use reth_db::database::Database;
use reth_interfaces::{
blockchain_tree::{
error::{BlockchainTreeError, InsertBlockErrorKind},
BlockAttachment, BlockValidationKind,
},
consensus::{Consensus, ConsensusError},
RethResult,
};
use reth_primitives::{

View File

@ -1,9 +1,10 @@
//! Blockchain tree externals.
use reth_consensus::Consensus;
use reth_db::{
cursor::DbCursorRO, database::Database, static_file::HeaderMask, tables, transaction::DbTx,
};
use reth_interfaces::{consensus::Consensus, RethResult};
use reth_interfaces::RethResult;
use reth_primitives::{BlockHash, BlockNumber, StaticFileSegment};
use reth_provider::{ProviderFactory, StatsReader};
use std::{collections::BTreeMap, sync::Arc};