sp-utils => sc-utils (#9677)

* sp-utils => sc-utils

* cargo fmt

* These files are now in the client so should be licensed as GPL3

* Apply suggestions from code review

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
This commit is contained in:
Squirrel
2021-09-04 20:20:48 +01:00
committed by GitHub
parent 8c3ad4300a
commit ffced22fb7
51 changed files with 206 additions and 194 deletions
+1 -1
View File
@@ -49,6 +49,7 @@ use sc_network::{
};
use sc_telemetry::{telemetry, ConnectionMessage, Telemetry, TelemetryHandle, SUBSTRATE_INFO};
use sc_transaction_pool_api::MaintainedTransactionPool;
use sc_utils::mpsc::{tracing_unbounded, TracingUnboundedSender};
use sp_api::{CallApiAt, ProvideRuntimeApi};
use sp_blockchain::{HeaderBackend, HeaderMetadata};
use sp_consensus::block_validation::{
@@ -61,7 +62,6 @@ use sp_runtime::{
traits::{Block as BlockT, BlockIdTo, HashFor, Zero},
BuildStorage,
};
use sp_utils::mpsc::{tracing_unbounded, TracingUnboundedSender};
use std::{str::FromStr, sync::Arc, time::SystemTime};
/// A utility trait for building an RPC extension given a `DenyUnsafe` instance.
@@ -61,6 +61,7 @@ use sp_blockchain::{
};
use sp_consensus::{BlockOrigin, BlockStatus, Error as ConsensusError};
use sc_utils::mpsc::{tracing_unbounded, TracingUnboundedSender};
use sp_core::{
convert_hash,
storage::{well_known_keys, ChildInfo, PrefixedStorageKey, StorageData, StorageKey},
@@ -82,7 +83,6 @@ use sp_state_machine::{
ChangesTrieConfigurationRange, ChangesTrieRootsStorage, ChangesTrieStorage, DBValue,
};
use sp_trie::StorageProof;
use sp_utils::mpsc::{tracing_unbounded, TracingUnboundedSender};
use std::{
collections::{BTreeMap, HashMap, HashSet},
marker::PhantomData,
+1 -1
View File
@@ -41,11 +41,11 @@ use futures::{stream, Future, FutureExt, Stream, StreamExt};
use log::{debug, error, warn};
use parity_util_mem::MallocSizeOf;
use sc_network::PeerId;
use sc_utils::mpsc::TracingUnboundedReceiver;
use sp_runtime::{
generic::BlockId,
traits::{Block as BlockT, Header as HeaderT},
};
use sp_utils::mpsc::TracingUnboundedReceiver;
pub use self::{
builder::{
+1 -1
View File
@@ -25,9 +25,9 @@ use sc_client_api::{ClientInfo, UsageProvider};
use sc_network::{config::Role, NetworkService, NetworkStatus};
use sc_telemetry::{telemetry, TelemetryHandle, SUBSTRATE_INFO};
use sc_transaction_pool_api::{MaintainedTransactionPool, PoolStatus};
use sc_utils::metrics::register_globals;
use sp_api::ProvideRuntimeApi;
use sp_runtime::traits::{Block, NumberFor, SaturatedConversion, UniqueSaturatedInto};
use sp_utils::metrics::register_globals;
use std::{
sync::Arc,
time::{Duration, Instant},
@@ -33,7 +33,7 @@ use prometheus_endpoint::{
exponential_buckets, register, CounterVec, HistogramOpts, HistogramVec, Opts, PrometheusError,
Registry, U64,
};
use sp_utils::mpsc::{tracing_unbounded, TracingUnboundedReceiver, TracingUnboundedSender};
use sc_utils::mpsc::{tracing_unbounded, TracingUnboundedReceiver, TracingUnboundedSender};
use std::{panic, pin::Pin, result::Result};
use tracing_futures::Instrument;