mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-19 11:11:03 +00:00
BlockId removal: &Hash to Hash (#6246)
* BlockId removal: &Hash to Hash It changes &Block::Hash argument to Block::Hash. This PR is part of BlockId::Number refactoring analysis (paritytech/substrate#11292) * missing file corrected * update lockfile for {"substrate"} Co-authored-by: parity-processbot <>
This commit is contained in:
committed by
GitHub
parent
fea94a1365
commit
8057d45a67
Generated
+180
-180
File diff suppressed because it is too large
Load Diff
@@ -327,7 +327,7 @@ impl UsageProvider<Block> for Client {
|
|||||||
impl sc_client_api::BlockBackend<Block> for Client {
|
impl sc_client_api::BlockBackend<Block> for Client {
|
||||||
fn block_body(
|
fn block_body(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
) -> sp_blockchain::Result<Option<Vec<<Block as BlockT>::Extrinsic>>> {
|
) -> sp_blockchain::Result<Option<Vec<<Block as BlockT>::Extrinsic>>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
self,
|
self,
|
||||||
@@ -360,7 +360,7 @@ impl sc_client_api::BlockBackend<Block> for Client {
|
|||||||
|
|
||||||
fn justifications(
|
fn justifications(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
) -> sp_blockchain::Result<Option<Justifications>> {
|
) -> sp_blockchain::Result<Option<Justifications>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
self,
|
self,
|
||||||
@@ -386,7 +386,7 @@ impl sc_client_api::BlockBackend<Block> for Client {
|
|||||||
|
|
||||||
fn indexed_transaction(
|
fn indexed_transaction(
|
||||||
&self,
|
&self,
|
||||||
id: &<Block as BlockT>::Hash,
|
id: <Block as BlockT>::Hash,
|
||||||
) -> sp_blockchain::Result<Option<Vec<u8>>> {
|
) -> sp_blockchain::Result<Option<Vec<u8>>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
self,
|
self,
|
||||||
@@ -399,7 +399,7 @@ impl sc_client_api::BlockBackend<Block> for Client {
|
|||||||
|
|
||||||
fn block_indexed_body(
|
fn block_indexed_body(
|
||||||
&self,
|
&self,
|
||||||
id: &<Block as BlockT>::Hash,
|
id: <Block as BlockT>::Hash,
|
||||||
) -> sp_blockchain::Result<Option<Vec<Vec<u8>>>> {
|
) -> sp_blockchain::Result<Option<Vec<Vec<u8>>>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
self,
|
self,
|
||||||
@@ -424,7 +424,7 @@ impl sc_client_api::BlockBackend<Block> for Client {
|
|||||||
impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
||||||
fn storage(
|
fn storage(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
key: &StorageKey,
|
key: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Option<StorageData>> {
|
) -> sp_blockchain::Result<Option<StorageData>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
@@ -438,7 +438,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn storage_keys(
|
fn storage_keys(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
key_prefix: &StorageKey,
|
key_prefix: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Vec<StorageKey>> {
|
) -> sp_blockchain::Result<Vec<StorageKey>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
@@ -452,7 +452,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn storage_hash(
|
fn storage_hash(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
key: &StorageKey,
|
key: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Option<<Block as BlockT>::Hash>> {
|
) -> sp_blockchain::Result<Option<<Block as BlockT>::Hash>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
@@ -466,7 +466,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn storage_pairs(
|
fn storage_pairs(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
key_prefix: &StorageKey,
|
key_prefix: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Vec<(StorageKey, StorageData)>> {
|
) -> sp_blockchain::Result<Vec<(StorageKey, StorageData)>> {
|
||||||
with_client! {
|
with_client! {
|
||||||
@@ -480,7 +480,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn storage_keys_iter<'a>(
|
fn storage_keys_iter<'a>(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
prefix: Option<&'a StorageKey>,
|
prefix: Option<&'a StorageKey>,
|
||||||
start_key: Option<&StorageKey>,
|
start_key: Option<&StorageKey>,
|
||||||
) -> sp_blockchain::Result<
|
) -> sp_blockchain::Result<
|
||||||
@@ -497,7 +497,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn child_storage(
|
fn child_storage(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
child_info: &ChildInfo,
|
child_info: &ChildInfo,
|
||||||
key: &StorageKey,
|
key: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Option<StorageData>> {
|
) -> sp_blockchain::Result<Option<StorageData>> {
|
||||||
@@ -512,7 +512,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn child_storage_keys(
|
fn child_storage_keys(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
child_info: &ChildInfo,
|
child_info: &ChildInfo,
|
||||||
key_prefix: &StorageKey,
|
key_prefix: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Vec<StorageKey>> {
|
) -> sp_blockchain::Result<Vec<StorageKey>> {
|
||||||
@@ -527,7 +527,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn child_storage_keys_iter<'a>(
|
fn child_storage_keys_iter<'a>(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
child_info: ChildInfo,
|
child_info: ChildInfo,
|
||||||
prefix: Option<&'a StorageKey>,
|
prefix: Option<&'a StorageKey>,
|
||||||
start_key: Option<&StorageKey>,
|
start_key: Option<&StorageKey>,
|
||||||
@@ -545,7 +545,7 @@ impl sc_client_api::StorageProvider<Block, crate::FullBackend> for Client {
|
|||||||
|
|
||||||
fn child_storage_hash(
|
fn child_storage_hash(
|
||||||
&self,
|
&self,
|
||||||
hash: &<Block as BlockT>::Hash,
|
hash: <Block as BlockT>::Hash,
|
||||||
child_info: &ChildInfo,
|
child_info: &ChildInfo,
|
||||||
key: &StorageKey,
|
key: &StorageKey,
|
||||||
) -> sp_blockchain::Result<Option<<Block as BlockT>::Hash>> {
|
) -> sp_blockchain::Result<Option<<Block as BlockT>::Hash>> {
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ fn basic_buy_fees_message_executes() {
|
|||||||
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
||||||
.expect("imports the block");
|
.expect("imports the block");
|
||||||
|
|
||||||
client.state_at(&block_hash).expect("state should exist").inspect_state(|| {
|
client.state_at(block_hash).expect("state should exist").inspect_state(|| {
|
||||||
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
||||||
r.event,
|
r.event,
|
||||||
polkadot_test_runtime::RuntimeEvent::Xcm(pallet_xcm::Event::Attempted(
|
polkadot_test_runtime::RuntimeEvent::Xcm(pallet_xcm::Event::Attempted(
|
||||||
@@ -101,7 +101,7 @@ fn query_response_fires() {
|
|||||||
.expect("imports the block");
|
.expect("imports the block");
|
||||||
|
|
||||||
let mut query_id = None;
|
let mut query_id = None;
|
||||||
client.state_at(&block_hash).expect("state should exist").inspect_state(|| {
|
client.state_at(block_hash).expect("state should exist").inspect_state(|| {
|
||||||
for r in polkadot_test_runtime::System::events().iter() {
|
for r in polkadot_test_runtime::System::events().iter() {
|
||||||
match r.event {
|
match r.event {
|
||||||
TestNotifier(QueryPrepared(q)) => query_id = Some(q),
|
TestNotifier(QueryPrepared(q)) => query_id = Some(q),
|
||||||
@@ -136,7 +136,7 @@ fn query_response_fires() {
|
|||||||
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
||||||
.expect("imports the block");
|
.expect("imports the block");
|
||||||
|
|
||||||
client.state_at(&block_hash).expect("state should exist").inspect_state(|| {
|
client.state_at(block_hash).expect("state should exist").inspect_state(|| {
|
||||||
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
||||||
r.event,
|
r.event,
|
||||||
polkadot_test_runtime::RuntimeEvent::Xcm(pallet_xcm::Event::ResponseReady(
|
polkadot_test_runtime::RuntimeEvent::Xcm(pallet_xcm::Event::ResponseReady(
|
||||||
@@ -184,7 +184,7 @@ fn query_response_elicits_handler() {
|
|||||||
.expect("imports the block");
|
.expect("imports the block");
|
||||||
|
|
||||||
let mut query_id = None;
|
let mut query_id = None;
|
||||||
client.state_at(&block_hash).expect("state should exist").inspect_state(|| {
|
client.state_at(block_hash).expect("state should exist").inspect_state(|| {
|
||||||
for r in polkadot_test_runtime::System::events().iter() {
|
for r in polkadot_test_runtime::System::events().iter() {
|
||||||
match r.event {
|
match r.event {
|
||||||
TestNotifier(NotifyQueryPrepared(q)) => query_id = Some(q),
|
TestNotifier(NotifyQueryPrepared(q)) => query_id = Some(q),
|
||||||
@@ -218,7 +218,7 @@ fn query_response_elicits_handler() {
|
|||||||
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
futures::executor::block_on(client.import(sp_consensus::BlockOrigin::Own, block))
|
||||||
.expect("imports the block");
|
.expect("imports the block");
|
||||||
|
|
||||||
client.state_at(&block_hash).expect("state should exist").inspect_state(|| {
|
client.state_at(block_hash).expect("state should exist").inspect_state(|| {
|
||||||
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
assert!(polkadot_test_runtime::System::events().iter().any(|r| matches!(
|
||||||
r.event,
|
r.event,
|
||||||
TestNotifier(ResponseReceived(
|
TestNotifier(ResponseReceived(
|
||||||
|
|||||||
Reference in New Issue
Block a user