Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
parity
Mirrored projects
polkadot
Commits
9164205e
Unverified
Commit
9164205e
authored
Mar 26, 2021
by
Bernhard Schuster
Committed by
GitHub
Mar 26, 2021
Browse files
chore: avoid glob imports (#2722)
parent
8621ed28
Pipeline
#130814
failed with stages
in 28 minutes and 36 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
bridges/modules/ethereum/src/benchmarking.rs
View file @
9164205e
...
@@ -14,7 +14,13 @@
...
@@ -14,7 +14,13 @@
// You should have received a copy of the GNU General Public License
// You should have received a copy of the GNU General Public License
// along with Parity Bridges Common. If not, see <http://www.gnu.org/licenses/>.
// along with Parity Bridges Common. If not, see <http://www.gnu.org/licenses/>.
use
super
::
*
;
use
super
::{
BridgeStorage
,
RawOrigin
,
HeadersByNumber
,
Instance
,
Config
,
};
use
crate
::
test_utils
::{
use
crate
::
test_utils
::{
build_custom_header
,
build_genesis_header
,
insert_header
,
validator_utils
::
*
,
validators_change_receipt
,
build_custom_header
,
build_genesis_header
,
insert_header
,
validator_utils
::
*
,
validators_change_receipt
,
...
...
bridges/relays/ethereum/src/substrate_sync_loop.rs
View file @
9164205e
...
@@ -42,7 +42,7 @@ use std::fmt::Debug;
...
@@ -42,7 +42,7 @@ use std::fmt::Debug;
use
std
::{
collections
::
HashSet
,
time
::
Duration
};
use
std
::{
collections
::
HashSet
,
time
::
Duration
};
pub
mod
consts
{
pub
mod
consts
{
use
super
::
*
;
use
super
::
Duration
;
/// Interval at which we check new Ethereum blocks.
/// Interval at which we check new Ethereum blocks.
pub
const
ETHEREUM_TICK_INTERVAL
:
Duration
=
Duration
::
from_secs
(
5
);
pub
const
ETHEREUM_TICK_INTERVAL
:
Duration
=
Duration
::
from_secs
(
5
);
...
...
node/metered-channel/src/bounded.rs
View file @
9164205e
...
@@ -16,7 +16,13 @@
...
@@ -16,7 +16,13 @@
//! Metered variant of bounded mpsc channels to be able to extract metrics.
//! Metered variant of bounded mpsc channels to be able to extract metrics.
use
super
::
*
;
use
futures
::{
channel
::
mpsc
,
task
::
Poll
,
task
::
Context
,
sink
::
SinkExt
,
stream
::
Stream
};
use
std
::
result
;
use
std
::
pin
::
Pin
;
use
super
::
Meter
;
/// Create a wrapped `mpsc::channel` pair of `MeteredSender` and `MeteredReceiver`.
/// Create a wrapped `mpsc::channel` pair of `MeteredSender` and `MeteredReceiver`.
pub
fn
channel
<
T
>
(
capacity
:
usize
,
name
:
&
'static
str
)
->
(
MeteredSender
<
T
>
,
MeteredReceiver
<
T
>
)
{
pub
fn
channel
<
T
>
(
capacity
:
usize
,
name
:
&
'static
str
)
->
(
MeteredSender
<
T
>
,
MeteredReceiver
<
T
>
)
{
...
...
node/metered-channel/src/lib.rs
View file @
9164205e
...
@@ -17,12 +17,7 @@
...
@@ -17,12 +17,7 @@
//! Metered variant of mpsc channels to be able to extract metrics.
//! Metered variant of mpsc channels to be able to extract metrics.
use
std
::
sync
::
atomic
::{
AtomicUsize
,
Ordering
};
use
std
::
sync
::
atomic
::{
AtomicUsize
,
Ordering
};
use
futures
::{
channel
::
mpsc
,
task
::
Poll
,
task
::
Context
,
sink
::
SinkExt
,
stream
::
Stream
};
use
std
::
result
;
use
std
::
sync
::
Arc
;
use
std
::
sync
::
Arc
;
use
std
::
pin
::
Pin
;
use
derive_more
::{
Add
,
Display
};
use
derive_more
::{
Add
,
Display
};
...
...
node/metered-channel/src/unbounded.rs
View file @
9164205e
...
@@ -16,7 +16,13 @@
...
@@ -16,7 +16,13 @@
//! Metered variant of unbounded mpsc channels to be able to extract metrics.
//! Metered variant of unbounded mpsc channels to be able to extract metrics.
use
super
::
*
;
use
futures
::{
channel
::
mpsc
,
task
::
Poll
,
task
::
Context
,
sink
::
SinkExt
,
stream
::
Stream
};
use
std
::
result
;
use
std
::
pin
::
Pin
;
use
super
::
Meter
;
/// Create a wrapped `mpsc::channel` pair of `MeteredSender` and `MeteredReceiver`.
/// Create a wrapped `mpsc::channel` pair of `MeteredSender` and `MeteredReceiver`.
pub
fn
unbounded
<
T
>
(
name
:
&
'static
str
)
->
(
UnboundedMeteredSender
<
T
>
,
UnboundedMeteredReceiver
<
T
>
)
{
pub
fn
unbounded
<
T
>
(
name
:
&
'static
str
)
->
(
UnboundedMeteredSender
<
T
>
,
UnboundedMeteredReceiver
<
T
>
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment