mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 13:57:58 +00:00
* Substrate companion #9491 https://github.com/paritytech/substrate/pull/9491 * update Substrate * Fix build Co-authored-by: parity-processbot <>
This commit is contained in:
Generated
+157
-158
File diff suppressed because it is too large
Load Diff
@@ -21,6 +21,7 @@ sc-consensus-slots = { git = "https://github.com/paritytech/substrate", branch =
|
||||
sc-executor = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
sc-network = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
sc-transaction-pool = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
sc-sync-state-rpc = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
sc-keystore = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
sc-basic-authorship = { git = "https://github.com/paritytech/substrate", branch = "master" }
|
||||
service = { package = "sc-service", git = "https://github.com/paritytech/substrate", branch = "master", default-features = false }
|
||||
|
||||
@@ -64,6 +64,10 @@ pub struct Extensions {
|
||||
pub fork_blocks: sc_client_api::ForkBlocks<polkadot_primitives::v1::Block>,
|
||||
/// Known bad block hashes.
|
||||
pub bad_blocks: sc_client_api::BadBlocks<polkadot_primitives::v1::Block>,
|
||||
/// The light sync state.
|
||||
///
|
||||
/// This value will be set by the `sync-state rpc` implementation.
|
||||
pub light_sync_state: sc_sync_state_rpc::LightSyncStateExtension,
|
||||
}
|
||||
|
||||
/// The `ChainSpec` parameterized for the polkadot runtime.
|
||||
|
||||
@@ -322,10 +322,7 @@ fn new_partial<RuntimeApi, Executor>(
|
||||
sc_consensus::DefaultImportQueue<Block, FullClient<RuntimeApi, Executor>>,
|
||||
sc_transaction_pool::FullPool<Block, FullClient<RuntimeApi, Executor>>,
|
||||
(
|
||||
impl Fn(
|
||||
polkadot_rpc::DenyUnsafe,
|
||||
polkadot_rpc::SubscriptionTaskExecutor,
|
||||
) -> polkadot_rpc::RpcExtension,
|
||||
impl service::RpcExtensionBuilder,
|
||||
(
|
||||
babe::BabeBlockImport<
|
||||
Block,
|
||||
@@ -469,7 +466,7 @@ where
|
||||
|
||||
move |deny_unsafe,
|
||||
subscription_executor: polkadot_rpc::SubscriptionTaskExecutor|
|
||||
-> polkadot_rpc::RpcExtension {
|
||||
-> Result<polkadot_rpc::RpcExtension, service::Error> {
|
||||
let deps = polkadot_rpc::FullDeps {
|
||||
client: client.clone(),
|
||||
pool: transaction_pool.clone(),
|
||||
@@ -494,7 +491,7 @@ where
|
||||
},
|
||||
};
|
||||
|
||||
polkadot_rpc::create_full(deps)
|
||||
polkadot_rpc::create_full(deps).map_err(Into::into)
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -105,7 +105,9 @@ pub struct FullDeps<C, P, SC, B> {
|
||||
}
|
||||
|
||||
/// Instantiate all RPC extensions.
|
||||
pub fn create_full<C, P, SC, B>(deps: FullDeps<C, P, SC, B>) -> RpcExtension
|
||||
pub fn create_full<C, P, SC, B>(
|
||||
deps: FullDeps<C, P, SC, B>,
|
||||
) -> Result<RpcExtension, Box<dyn std::error::Error + Send + Sync>>
|
||||
where
|
||||
C: ProvideRuntimeApi<Block>
|
||||
+ HeaderBackend<Block>
|
||||
@@ -166,7 +168,7 @@ where
|
||||
shared_authority_set,
|
||||
shared_epoch_changes,
|
||||
deny_unsafe,
|
||||
)));
|
||||
)?));
|
||||
|
||||
io.extend_with(beefy_gadget_rpc::BeefyApi::to_delegate(
|
||||
beefy_gadget_rpc::BeefyRpcHandler::new(
|
||||
@@ -175,7 +177,7 @@ where
|
||||
),
|
||||
));
|
||||
|
||||
io
|
||||
Ok(io)
|
||||
}
|
||||
|
||||
/// Instantiate all RPC extensions for light node.
|
||||
|
||||
@@ -1564,20 +1564,11 @@ mod benchmarking {
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
use crate::claims::tests::{new_test_ext, Test};
|
||||
use frame_support::assert_ok;
|
||||
|
||||
#[test]
|
||||
fn test_benchmarks() {
|
||||
new_test_ext().execute_with(|| {
|
||||
assert_ok!(test_benchmark_claim::<Test>());
|
||||
assert_ok!(test_benchmark_mint_claim::<Test>());
|
||||
assert_ok!(test_benchmark_claim_attest::<Test>());
|
||||
assert_ok!(test_benchmark_attest::<Test>());
|
||||
assert_ok!(test_benchmark_move_claim::<Test>());
|
||||
assert_ok!(test_benchmark_keccak256::<Test>());
|
||||
assert_ok!(test_benchmark_eth_recover::<Test>());
|
||||
});
|
||||
}
|
||||
frame_benchmarking::impl_benchmark_test_suite!(
|
||||
Pallet,
|
||||
crate::claims::tests::new_test_ext(),
|
||||
crate::claims::tests::Test,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user