Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
dailinsubjam committed Sep 22, 2023
1 parent 417ab81 commit d5c0786
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions crates/hotshot/src/traits/networking.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,11 @@ pub mod libp2p_network;
pub mod memory_network;
pub mod web_server_libp2p_fallback;
pub mod web_server_network;

use hotshot_types::traits::metrics::{Counter, Gauge, Metrics};
pub use hotshot_types::traits::network::{
ChannelSendSnafu, CouldNotDeliverSnafu, FailedToDeserializeSnafu, FailedToSerializeSnafu,
NetworkError, NetworkReliability, NoSuchNodeSnafu, ShutDownSnafu,
};
use hotshot_types::traits::metrics::{Counter, Gauge, Metrics};

/// Contains the metrics that we're interested in from the networking interfaces
#[derive(Clone)]
Expand Down
1 change: 0 additions & 1 deletion crates/hotshot/src/traits/networking/libp2p_network.rs
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,6 @@ impl<M: NetworkMsg, K: SignatureKey + 'static> Libp2pNetwork<M, K> {

let connected_num = handle.num_connected().await?;
metrics_connected_peers.set(connected_num);

while !is_bootstrapped.load(Ordering::Relaxed) {
async_sleep(Duration::from_secs(1)).await;
}
Expand Down
2 changes: 1 addition & 1 deletion crates/types/src/traits/metrics.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
//! - [`Histogram`]: stores multiple float values based for a graph (example usage: CPU %)
//! - [`Label`]: Stores the last string (example usage: current version, network online/offline)

use std::fmt::Debug;
use dyn_clone::DynClone;
use std::fmt::Debug;

/// The metrics type.
pub trait Metrics: Send + Sync {
Expand Down

0 comments on commit d5c0786

Please sign in to comment.