Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
rustfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
rphmeier committed Jun 7, 2023
1 parent 3afbfe7 commit 89af9a6
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 8 deletions.
5 changes: 3 additions & 2 deletions client/consensus/aura/src/collators/lookahead.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,10 @@ use cumulus_client_consensus_common::{
self as consensus_common, ParachainBlockImportMarker, ParentSearchParams,
};
use cumulus_client_consensus_proposer::ProposerInterface;
use cumulus_primitives_aura::AuraUnincludedSegmentApi;
use cumulus_primitives_core::{
relay_chain::Hash as PHash, CollectCollationInfo, PersistedValidationData,
};
use cumulus_primitives_aura::AuraUnincludedSegmentApi;
use cumulus_relay_chain_interface::RelayChainInterface;

use polkadot_overseer::Handle as OverseerHandle;
Expand Down Expand Up @@ -96,7 +96,8 @@ pub async fn run<Block, P, BI, CIDP, Client, Backend, RClient, SO, Proposer, CS>
+ Send
+ Sync
+ 'static,
Client::Api: AuraApi<Block, P::Public> + CollectCollationInfo<Block> + AuraUnincludedSegmentApi<Block>,
Client::Api:
AuraApi<Block, P::Public> + CollectCollationInfo<Block> + AuraUnincludedSegmentApi<Block>,
Backend: sp_blockchain::Backend<Block>,
RClient: RelayChainInterface,
CIDP: CreateInherentDataProviders<Block, ()> + 'static,
Expand Down
5 changes: 2 additions & 3 deletions client/consensus/aura/src/equivocation_import_queue.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@
/// Equivocation resistance in general is a hard problem, as different nodes in the network
/// may see equivocations in a different order, and therefore may not agree on which blocks
/// should be thrown out and which ones should be kept.

use codec::{Decode, Encode};
use lru::LruCache;
use cumulus_client_consensus_common::ParachainBlockImportMarker;
use lru::LruCache;

use sc_consensus::{
import_queue::{BasicQueue, Verifier as VerifierT},
Expand Down Expand Up @@ -136,7 +135,7 @@ where
return Err(format!(
"Rejecting block {:?} due to excessive equivocations at slot",
post_hash,
));
))
}
},
Err(aura_internal::SealVerificationError::Deferred(hdr, slot)) => {
Expand Down
6 changes: 4 additions & 2 deletions client/network/src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,8 +243,10 @@ impl RelayChainInterface for DummyRelayChainInterface {
}
}

fn make_validator_and_api(
) -> (RequireSecondedInBlockAnnounce<Block, Arc<DummyRelayChainInterface>>, Arc<DummyRelayChainInterface>) {
fn make_validator_and_api() -> (
RequireSecondedInBlockAnnounce<Block, Arc<DummyRelayChainInterface>>,
Arc<DummyRelayChainInterface>,
) {
let relay_chain_interface = Arc::new(DummyRelayChainInterface::new());
(
RequireSecondedInBlockAnnounce::new(relay_chain_interface.clone(), ParaId::from(56)),
Expand Down
3 changes: 2 additions & 1 deletion client/service/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,8 @@ where
_ => None,
};

let block_announce_validator = RequireSecondedInBlockAnnounce::new(relay_chain_interface, para_id);
let block_announce_validator =
RequireSecondedInBlockAnnounce::new(relay_chain_interface, para_id);
let block_announce_validator_builder = move |_| Box::new(block_announce_validator) as Box<_>;

sc_service::build_network(sc_service::BuildNetworkParams {
Expand Down

0 comments on commit 89af9a6

Please sign in to comment.