mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
chore(deps): rm reth-rpc-types dep from reth-network (#9023)
This commit is contained in:
@ -14,7 +14,7 @@ workspace = true
|
||||
[dependencies]
|
||||
# reth
|
||||
reth-eth-wire.workspace = true
|
||||
reth-rpc-types.workspace = true
|
||||
alloy-rpc-types-admin.workspace = true
|
||||
reth-network-peers.workspace = true
|
||||
|
||||
# ethereum
|
||||
|
||||
@ -13,13 +13,13 @@
|
||||
)]
|
||||
#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))]
|
||||
|
||||
use reth_eth_wire::{capability::Capabilities, DisconnectReason, EthVersion, Status};
|
||||
use reth_rpc_types::NetworkStatus;
|
||||
use std::{future::Future, net::SocketAddr, sync::Arc, time::Instant};
|
||||
|
||||
pub use alloy_rpc_types_admin::EthProtocolInfo;
|
||||
pub use error::NetworkError;
|
||||
pub use reputation::{Reputation, ReputationChangeKind};
|
||||
use reth_eth_wire::{capability::Capabilities, DisconnectReason, EthVersion, Status};
|
||||
use reth_network_peers::NodeRecord;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::{future::Future, net::SocketAddr, sync::Arc, time::Instant};
|
||||
|
||||
/// The `PeerId` type.
|
||||
pub type PeerId = alloy_primitives::B512;
|
||||
@ -215,3 +215,14 @@ impl std::fmt::Display for Direction {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// The status of the network being ran by the local node.
|
||||
#[derive(Clone, Debug, Serialize, Deserialize)]
|
||||
pub struct NetworkStatus {
|
||||
/// The local node client version.
|
||||
pub client_version: String,
|
||||
/// The current ethereum protocol version
|
||||
pub protocol_version: u64,
|
||||
/// Information about the Ethereum Wire Protocol.
|
||||
pub eth_protocol_info: EthProtocolInfo,
|
||||
}
|
||||
|
||||
@ -4,13 +4,13 @@
|
||||
//! generic over it.
|
||||
|
||||
use crate::{
|
||||
NetworkError, NetworkInfo, PeerId, PeerInfo, PeerKind, Peers, PeersInfo, Reputation,
|
||||
ReputationChangeKind,
|
||||
NetworkError, NetworkInfo, NetworkStatus, PeerId, PeerInfo, PeerKind, Peers, PeersInfo,
|
||||
Reputation, ReputationChangeKind,
|
||||
};
|
||||
use alloy_rpc_types_admin::EthProtocolInfo;
|
||||
use enr::{secp256k1::SecretKey, Enr};
|
||||
use reth_eth_wire::{DisconnectReason, ProtocolVersion};
|
||||
use reth_network_peers::NodeRecord;
|
||||
use reth_rpc_types::{admin::EthProtocolInfo, NetworkStatus};
|
||||
use std::net::{IpAddr, SocketAddr};
|
||||
|
||||
/// A type that implements all network trait that does nothing.
|
||||
|
||||
Reference in New Issue
Block a user