@@ -45,6 +45,7 @@ use log::{debug, trace};
45
45
use codec:: { Codec , Decode , Encode } ;
46
46
47
47
use sc_client_api:: { backend:: AuxStore , BlockOf , UsageProvider } ;
48
+ use sc_consensus:: { BlockImport , BlockImportParams , ForkChoiceStrategy , StateAction } ;
48
49
use sc_consensus_slots:: {
49
50
BackoffAuthoringBlocksStrategy , InherentDataProviderExt , SlotInfo , StorageChanges ,
50
51
} ;
@@ -53,8 +54,7 @@ use sp_api::ProvideRuntimeApi;
53
54
use sp_application_crypto:: { AppKey , AppPublic } ;
54
55
use sp_blockchain:: { HeaderBackend , ProvideCache , Result as CResult } ;
55
56
use sp_consensus:: {
56
- BlockImport , BlockImportParams , BlockOrigin , CanAuthorWith , Environment ,
57
- Error as ConsensusError , ForkChoiceStrategy , Proposer , SelectChain , StateAction ,
57
+ BlockOrigin , CanAuthorWith , Environment , Error as ConsensusError , Proposer , SelectChain ,
58
58
} ;
59
59
use sp_consensus_slots:: Slot ;
60
60
use sp_core:: crypto:: { Pair , Public } ;
@@ -185,7 +185,7 @@ where
185
185
PF : Environment < B , Error = Error > + Send + Sync + ' static ,
186
186
PF :: Proposer : Proposer < B , Error = Error , Transaction = sp_api:: TransactionFor < C , B > > ,
187
187
SO : SyncOracle + Send + Sync + Clone ,
188
- L : sp_consensus :: JustificationSyncLink < B > ,
188
+ L : sc_consensus :: JustificationSyncLink < B > ,
189
189
CIDP : CreateInherentDataProviders < B , ( ) > + Send ,
190
190
CIDP :: InherentDataProviders : InherentDataProviderExt + Send ,
191
191
BS : BackoffAuthoringBlocksStrategy < NumberFor < B > > + Send + ' static ,
@@ -277,7 +277,7 @@ where
277
277
I : BlockImport < B , Transaction = sp_api:: TransactionFor < C , B > > + Send + Sync + ' static ,
278
278
Error : std:: error:: Error + Send + From < sp_consensus:: Error > + ' static ,
279
279
SO : SyncOracle + Send + Sync + Clone ,
280
- L : sp_consensus :: JustificationSyncLink < B > ,
280
+ L : sc_consensus :: JustificationSyncLink < B > ,
281
281
BS : BackoffAuthoringBlocksStrategy < NumberFor < B > > + Send + ' static ,
282
282
{
283
283
AuraWorker {
@@ -324,7 +324,7 @@ where
324
324
P :: Public : AppPublic + Public + Member + Encode + Decode + Hash ,
325
325
P :: Signature : TryFrom < Vec < u8 > > + Member + Encode + Decode + Hash + Debug ,
326
326
SO : SyncOracle + Send + Clone ,
327
- L : sp_consensus :: JustificationSyncLink < B > ,
327
+ L : sc_consensus :: JustificationSyncLink < B > ,
328
328
BS : BackoffAuthoringBlocksStrategy < NumberFor < B > > + Send + ' static ,
329
329
Error : std:: error:: Error + Send + From < sp_consensus:: Error > + ' static ,
330
330
{
@@ -395,7 +395,7 @@ where
395
395
Self :: Claim ,
396
396
Self :: EpochData ,
397
397
) -> Result <
398
- sp_consensus :: BlockImportParams < B , sp_api:: TransactionFor < C , B > > ,
398
+ sc_consensus :: BlockImportParams < B , sp_api:: TransactionFor < C , B > > ,
399
399
sp_consensus:: Error ,
400
400
> + Send
401
401
+ ' static ,
@@ -431,7 +431,7 @@ where
431
431
import_block. post_digests . push ( signature_digest_item) ;
432
432
import_block. body = Some ( body) ;
433
433
import_block. state_action =
434
- StateAction :: ApplyChanges ( sp_consensus :: StorageChanges :: Changes ( storage_changes) ) ;
434
+ StateAction :: ApplyChanges ( sc_consensus :: StorageChanges :: Changes ( storage_changes) ) ;
435
435
import_block. fork_choice = Some ( ForkChoiceStrategy :: LongestChain ) ;
436
436
437
437
Ok ( import_block)
@@ -560,14 +560,14 @@ mod tests {
560
560
use parking_lot:: Mutex ;
561
561
use sc_block_builder:: BlockBuilderProvider ;
562
562
use sc_client_api:: BlockchainEvents ;
563
+ use sc_consensus:: BoxJustificationImport ;
563
564
use sc_consensus_slots:: { BackoffAuthoringOnFinalizedHeadLagging , SimpleSlotWorker } ;
564
565
use sc_keystore:: LocalKeystore ;
565
566
use sc_network:: config:: ProtocolConfig ;
566
567
use sc_network_test:: { Block as TestBlock , * } ;
567
568
use sp_application_crypto:: key_types:: AURA ;
568
569
use sp_consensus:: {
569
- import_queue:: BoxJustificationImport , AlwaysCanAuthor , DisableProofRecording ,
570
- NoNetwork as DummyOracle , Proposal , SlotData ,
570
+ AlwaysCanAuthor , DisableProofRecording , NoNetwork as DummyOracle , Proposal , SlotData ,
571
571
} ;
572
572
use sp_consensus_aura:: sr25519:: AuthorityPair ;
573
573
use sp_inherents:: InherentData ;
0 commit comments