Skip to content

Commit ab85300

Browse files
authored
chore: changed import for network-txpool(examples) (#15643)
1 parent e261a2e commit ab85300

File tree

3 files changed

+12
-14
lines changed

3 files changed

+12
-14
lines changed

Diff for: Cargo.lock

+1-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: examples/network-txpool/Cargo.toml

+1-3
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ license.workspace = true
77

88
[dependencies]
99
alloy-consensus.workspace = true
10-
reth-provider = { workspace = true, features = ["test-utils"] }
10+
reth-ethereum = { workspace = true, features = ["test-utils", "network", "pool", "provider"] }
1111
eyre.workspace = true
1212
tokio.workspace = true
13-
reth-network.workspace = true
14-
reth-transaction-pool.workspace = true

Diff for: examples/network-txpool/src/main.rs

+10-8
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,14 @@
1010
#![warn(unused_crate_dependencies)]
1111

1212
use alloy_consensus::Transaction;
13-
use reth_network::{config::rng_secret_key, EthNetworkPrimitives, NetworkConfig, NetworkManager};
14-
use reth_provider::test_utils::NoopProvider;
15-
use reth_transaction_pool::{
16-
blobstore::InMemoryBlobStore, validate::ValidTransaction, CoinbaseTipOrdering,
17-
EthPooledTransaction, PoolTransaction, TransactionListenerKind, TransactionOrigin,
18-
TransactionPool, TransactionValidationOutcome, TransactionValidator,
13+
use reth_ethereum::{
14+
network::{config::rng_secret_key, EthNetworkPrimitives, NetworkConfig, NetworkManager},
15+
pool::{
16+
blobstore::InMemoryBlobStore, validate::ValidTransaction, CoinbaseTipOrdering,
17+
EthPooledTransaction, PoolTransaction, TransactionListenerKind, TransactionOrigin,
18+
TransactionPool, TransactionValidationOutcome, TransactionValidator,
19+
},
20+
provider::test_utils::NoopProvider,
1921
};
2022

2123
#[tokio::main]
@@ -26,7 +28,7 @@ async fn main() -> eyre::Result<()> {
2628
// remote or able to validate transaction against the latest state.
2729
let client = NoopProvider::default();
2830

29-
let pool = reth_transaction_pool::Pool::new(
31+
let pool = reth_ethereum::pool::Pool::new(
3032
OkValidator::default(),
3133
CoinbaseTipOrdering::default(),
3234
InMemoryBlobStore::default(),
@@ -68,7 +70,7 @@ async fn main() -> eyre::Result<()> {
6870
/// A transaction validator that determines all transactions to be valid.
6971
///
7072
/// An actual validator impl like
71-
/// [TransactionValidationTaskExecutor](reth_transaction_pool::TransactionValidationTaskExecutor)
73+
/// [TransactionValidationTaskExecutor](reth_ethereum::pool::TransactionValidationTaskExecutor)
7274
/// would require up to date db access.
7375
///
7476
/// CAUTION: This validator is not safe to use since it doesn't actually validate the transaction's

0 commit comments

Comments
 (0)