mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-19 20:31:04 +00:00
companion for substrate#13883 (#7059)
* companion for substrate#13883
* update lockfile for {"substrate"}
---------
Co-authored-by: parity-processbot <>
This commit is contained in:
Generated
+188
-188
File diff suppressed because it is too large
Load Diff
@@ -531,7 +531,7 @@ where
|
|||||||
babe::block_import(babe_config.clone(), beefy_block_import, client.clone())?;
|
babe::block_import(babe_config.clone(), beefy_block_import, client.clone())?;
|
||||||
|
|
||||||
let slot_duration = babe_link.config().slot_duration();
|
let slot_duration = babe_link.config().slot_duration();
|
||||||
let import_queue = babe::import_queue(
|
let (import_queue, babe_worker_handle) = babe::import_queue(
|
||||||
babe_link.clone(),
|
babe_link.clone(),
|
||||||
block_import.clone(),
|
block_import.clone(),
|
||||||
Some(Box::new(justification_import)),
|
Some(Box::new(justification_import)),
|
||||||
@@ -561,9 +561,6 @@ where
|
|||||||
Some(shared_authority_set.clone()),
|
Some(shared_authority_set.clone()),
|
||||||
);
|
);
|
||||||
|
|
||||||
let shared_epoch_changes = babe_link.epoch_changes().clone();
|
|
||||||
let slot_duration = babe_config.slot_duration();
|
|
||||||
|
|
||||||
let import_setup = (block_import, grandpa_link, babe_link, beefy_voter_links);
|
let import_setup = (block_import, grandpa_link, babe_link, beefy_voter_links);
|
||||||
let rpc_setup = shared_voter_state.clone();
|
let rpc_setup = shared_voter_state.clone();
|
||||||
|
|
||||||
@@ -585,8 +582,7 @@ where
|
|||||||
chain_spec: chain_spec.cloned_box(),
|
chain_spec: chain_spec.cloned_box(),
|
||||||
deny_unsafe,
|
deny_unsafe,
|
||||||
babe: polkadot_rpc::BabeDeps {
|
babe: polkadot_rpc::BabeDeps {
|
||||||
babe_config: babe_config.clone(),
|
babe_worker_handle: babe_worker_handle.clone(),
|
||||||
shared_epoch_changes: shared_epoch_changes.clone(),
|
|
||||||
keystore: keystore.clone(),
|
keystore: keystore.clone(),
|
||||||
},
|
},
|
||||||
grandpa: polkadot_rpc::GrandpaDeps {
|
grandpa: polkadot_rpc::GrandpaDeps {
|
||||||
|
|||||||
+6
-16
@@ -23,7 +23,6 @@ use std::sync::Arc;
|
|||||||
use jsonrpsee::RpcModule;
|
use jsonrpsee::RpcModule;
|
||||||
use polkadot_primitives::{AccountId, Balance, Block, BlockNumber, Hash, Nonce};
|
use polkadot_primitives::{AccountId, Balance, Block, BlockNumber, Hash, Nonce};
|
||||||
use sc_client_api::AuxStore;
|
use sc_client_api::AuxStore;
|
||||||
use sc_consensus_babe::{BabeConfiguration, Epoch};
|
|
||||||
use sc_consensus_beefy::communication::notification::{
|
use sc_consensus_beefy::communication::notification::{
|
||||||
BeefyBestBlockStream, BeefyVersionedFinalityProofStream,
|
BeefyBestBlockStream, BeefyVersionedFinalityProofStream,
|
||||||
};
|
};
|
||||||
@@ -42,10 +41,8 @@ pub type RpcExtension = RpcModule<()>;
|
|||||||
|
|
||||||
/// Extra dependencies for BABE.
|
/// Extra dependencies for BABE.
|
||||||
pub struct BabeDeps {
|
pub struct BabeDeps {
|
||||||
/// BABE protocol config.
|
/// A handle to the BABE worker for issuing requests.
|
||||||
pub babe_config: BabeConfiguration,
|
pub babe_worker_handle: sc_consensus_babe::BabeWorkerHandle<Block>,
|
||||||
/// BABE pending epoch changes.
|
|
||||||
pub shared_epoch_changes: sc_consensus_epochs::SharedEpochChanges<Block, Epoch>,
|
|
||||||
/// The keystore that manages the keys of the node.
|
/// The keystore that manages the keys of the node.
|
||||||
pub keystore: KeystorePtr,
|
pub keystore: KeystorePtr,
|
||||||
}
|
}
|
||||||
@@ -129,7 +126,7 @@ where
|
|||||||
let mut io = RpcModule::new(());
|
let mut io = RpcModule::new(());
|
||||||
let FullDeps { client, pool, select_chain, chain_spec, deny_unsafe, babe, grandpa, beefy } =
|
let FullDeps { client, pool, select_chain, chain_spec, deny_unsafe, babe, grandpa, beefy } =
|
||||||
deps;
|
deps;
|
||||||
let BabeDeps { keystore, babe_config, shared_epoch_changes } = babe;
|
let BabeDeps { babe_worker_handle, keystore } = babe;
|
||||||
let GrandpaDeps {
|
let GrandpaDeps {
|
||||||
shared_voter_state,
|
shared_voter_state,
|
||||||
shared_authority_set,
|
shared_authority_set,
|
||||||
@@ -143,15 +140,8 @@ where
|
|||||||
io.merge(TransactionPayment::new(client.clone()).into_rpc())?;
|
io.merge(TransactionPayment::new(client.clone()).into_rpc())?;
|
||||||
io.merge(Mmr::new(client.clone()).into_rpc())?;
|
io.merge(Mmr::new(client.clone()).into_rpc())?;
|
||||||
io.merge(
|
io.merge(
|
||||||
Babe::new(
|
Babe::new(client.clone(), babe_worker_handle.clone(), keystore, select_chain, deny_unsafe)
|
||||||
client.clone(),
|
.into_rpc(),
|
||||||
shared_epoch_changes.clone(),
|
|
||||||
keystore,
|
|
||||||
babe_config,
|
|
||||||
select_chain,
|
|
||||||
deny_unsafe,
|
|
||||||
)
|
|
||||||
.into_rpc(),
|
|
||||||
)?;
|
)?;
|
||||||
io.merge(
|
io.merge(
|
||||||
Grandpa::new(
|
Grandpa::new(
|
||||||
@@ -164,7 +154,7 @@ where
|
|||||||
.into_rpc(),
|
.into_rpc(),
|
||||||
)?;
|
)?;
|
||||||
io.merge(
|
io.merge(
|
||||||
SyncState::new(chain_spec, client, shared_authority_set, shared_epoch_changes)?.into_rpc(),
|
SyncState::new(chain_spec, client, shared_authority_set, babe_worker_handle)?.into_rpc(),
|
||||||
)?;
|
)?;
|
||||||
|
|
||||||
io.merge(
|
io.merge(
|
||||||
|
|||||||
Reference in New Issue
Block a user