mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 07:37:57 +00:00
BlockId removal: tx-pool refactor (#1678)
It changes following APIs: - trait `ChainApi` -- `validate_transaction` - trait `TransactionPool` --`submit_at` --`submit_one` --`submit_and_watch` and some implementation details, in particular: - impl `Pool` --`submit_at` --`resubmit_at` --`submit_one` --`submit_and_watch` --`prune_known` --`prune` --`prune_tags` --`resolve_block_number` --`verify` --`verify_one` - revalidation queue All tests are also adjusted. --------- Co-authored-by: command-bot <> Co-authored-by: Bastian Köcher <git@kchr.de>
This commit is contained in:
committed by
GitHub
parent
a846b74604
commit
ab3a3bc278
@@ -34,7 +34,7 @@ use sc_transaction_pool::PoolLimit;
|
||||
use sc_transaction_pool_api::{TransactionPool as _, TransactionSource, TransactionStatus};
|
||||
use sp_core::{crypto::Pair, sr25519};
|
||||
use sp_keyring::Sr25519Keyring;
|
||||
use sp_runtime::{generic::BlockId, OpaqueExtrinsic};
|
||||
use sp_runtime::OpaqueExtrinsic;
|
||||
use tokio::runtime::Handle;
|
||||
|
||||
fn new_node(tokio_handle: Handle) -> node_cli::service::NewFullBase {
|
||||
@@ -191,7 +191,7 @@ async fn submit_tx_and_wait_for_inclusion(
|
||||
let best_hash = client.chain_info().best_hash;
|
||||
|
||||
let mut watch = tx_pool
|
||||
.submit_and_watch(&BlockId::Hash(best_hash), TransactionSource::External, tx.clone())
|
||||
.submit_and_watch(best_hash, TransactionSource::External, tx.clone())
|
||||
.await
|
||||
.expect("Submits tx to pool")
|
||||
.fuse();
|
||||
|
||||
Reference in New Issue
Block a user