mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 19:09:54 +00:00
chore: reduce reth-primitives usage in node-core (#13000)
This commit is contained in:
1
Cargo.lock
generated
1
Cargo.lock
generated
@ -8067,6 +8067,7 @@ dependencies = [
|
|||||||
"reth-db",
|
"reth-db",
|
||||||
"reth-discv4",
|
"reth-discv4",
|
||||||
"reth-discv5",
|
"reth-discv5",
|
||||||
|
"reth-ethereum-forks",
|
||||||
"reth-net-nat",
|
"reth-net-nat",
|
||||||
"reth-network",
|
"reth-network",
|
||||||
"reth-network-p2p",
|
"reth-network-p2p",
|
||||||
|
|||||||
@ -34,6 +34,7 @@ reth-net-nat.workspace = true
|
|||||||
reth-network-peers.workspace = true
|
reth-network-peers.workspace = true
|
||||||
reth-prune-types.workspace = true
|
reth-prune-types.workspace = true
|
||||||
reth-stages-types.workspace = true
|
reth-stages-types.workspace = true
|
||||||
|
reth-ethereum-forks.workspace = true
|
||||||
|
|
||||||
# ethereum
|
# ethereum
|
||||||
alloy-primitives.workspace = true
|
alloy-primitives.workspace = true
|
||||||
|
|||||||
@ -15,9 +15,11 @@ pub mod exit;
|
|||||||
pub mod node_config;
|
pub mod node_config;
|
||||||
pub mod utils;
|
pub mod utils;
|
||||||
pub mod version;
|
pub mod version;
|
||||||
/// Re-exported from `reth_primitives`.
|
|
||||||
|
/// Re-exported primitive types
|
||||||
pub mod primitives {
|
pub mod primitives {
|
||||||
pub use reth_primitives::*;
|
pub use reth_ethereum_forks::*;
|
||||||
|
pub use reth_primitives_traits::*;
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Re-export of `reth_rpc_*` crates.
|
/// Re-export of `reth_rpc_*` crates.
|
||||||
|
|||||||
@ -9,22 +9,26 @@ use crate::{
|
|||||||
utils::get_single_header,
|
utils::get_single_header,
|
||||||
};
|
};
|
||||||
use alloy_consensus::BlockHeader;
|
use alloy_consensus::BlockHeader;
|
||||||
|
use alloy_eips::BlockHashOrNumber;
|
||||||
|
use alloy_primitives::{BlockNumber, B256};
|
||||||
use eyre::eyre;
|
use eyre::eyre;
|
||||||
use reth_chainspec::{ChainSpec, EthChainSpec, MAINNET};
|
use reth_chainspec::{ChainSpec, EthChainSpec, MAINNET};
|
||||||
use reth_config::config::PruneConfig;
|
use reth_config::config::PruneConfig;
|
||||||
|
use reth_ethereum_forks::Head;
|
||||||
use reth_network_p2p::headers::client::HeadersClient;
|
use reth_network_p2p::headers::client::HeadersClient;
|
||||||
use serde::{de::DeserializeOwned, Serialize};
|
use reth_primitives_traits::SealedHeader;
|
||||||
use std::{fs, path::Path};
|
|
||||||
|
|
||||||
use alloy_eips::BlockHashOrNumber;
|
|
||||||
use alloy_primitives::{BlockNumber, B256};
|
|
||||||
use reth_primitives::{Head, SealedHeader};
|
|
||||||
use reth_stages_types::StageId;
|
use reth_stages_types::StageId;
|
||||||
use reth_storage_api::{
|
use reth_storage_api::{
|
||||||
BlockHashReader, DatabaseProviderFactory, HeaderProvider, StageCheckpointReader,
|
BlockHashReader, DatabaseProviderFactory, HeaderProvider, StageCheckpointReader,
|
||||||
};
|
};
|
||||||
use reth_storage_errors::provider::ProviderResult;
|
use reth_storage_errors::provider::ProviderResult;
|
||||||
use std::{net::SocketAddr, path::PathBuf, sync::Arc};
|
use serde::{de::DeserializeOwned, Serialize};
|
||||||
|
use std::{
|
||||||
|
fs,
|
||||||
|
net::SocketAddr,
|
||||||
|
path::{Path, PathBuf},
|
||||||
|
sync::Arc,
|
||||||
|
};
|
||||||
use tracing::*;
|
use tracing::*;
|
||||||
|
|
||||||
/// This includes all necessary configuration to launch the node.
|
/// This includes all necessary configuration to launch the node.
|
||||||
|
|||||||
@ -9,7 +9,8 @@ use reth_consensus::Consensus;
|
|||||||
use reth_network_p2p::{
|
use reth_network_p2p::{
|
||||||
bodies::client::BodiesClient, headers::client::HeadersClient, priority::Priority,
|
bodies::client::BodiesClient, headers::client::HeadersClient, priority::Priority,
|
||||||
};
|
};
|
||||||
use reth_primitives::{SealedBlock, SealedHeader};
|
use reth_primitives::SealedBlock;
|
||||||
|
use reth_primitives_traits::SealedHeader;
|
||||||
use std::{
|
use std::{
|
||||||
env::VarError,
|
env::VarError,
|
||||||
path::{Path, PathBuf},
|
path::{Path, PathBuf},
|
||||||
|
|||||||
Reference in New Issue
Block a user