Remove extern crate (#5922)

* Remove extern crate
This commit is contained in:
Michael Sproul
2024-06-18 01:05:21 +10:00
committed by GitHub
parent 44c03d5d17
commit 21f3a191c5
33 changed files with 23 additions and 41 deletions

View File

@@ -2,9 +2,6 @@
/// all required libp2p functionality.
///
/// This crate builds and manages the libp2p services required by the beacon node.
#[macro_use]
extern crate lazy_static;
mod config;
pub mod service;

View File

@@ -1,5 +1,7 @@
pub use lighthouse_metrics::*;
use lazy_static::lazy_static;
lazy_static! {
pub static ref NAT_OPEN: Result<IntGaugeVec> = try_create_int_gauge_vec(
"nat_open",

View File

@@ -6,6 +6,7 @@
//!
//! The scoring algorithms are currently experimental.
use crate::service::gossipsub_scoring_parameters::GREYLIST_THRESHOLD as GOSSIPSUB_GREYLIST_THRESHOLD;
use lazy_static::lazy_static;
use serde::Serialize;
use std::time::Instant;
use strum::AsRefStr;

View File

@@ -3,6 +3,7 @@ use crate::rpc::codec::{base::BaseInboundCodec, ssz_snappy::SSZSnappyInboundCode
use futures::future::BoxFuture;
use futures::prelude::{AsyncRead, AsyncWrite};
use futures::{FutureExt, StreamExt};
use lazy_static::lazy_static;
use libp2p::core::{InboundUpgrade, UpgradeInfo};
use ssz::Encode;
use ssz_types::VariableList;