mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 17:28:00 +00:00
Recover transaction pool on light client (#3833)
* recover tx pool on light client * revert local tests fix * removed import renamings * futures03::Future -> std::future::Future * Update core/transaction-pool/graph/src/error.rs Co-Authored-By: Tomasz Drwięga <tomusdrw@users.noreply.github.com> * replace remove_from_ready with remove_invalid * avoid excess hashing * debug -> warn * TransactionPool + BasicTransactionPool * pause future tx reject when resubmitting * bump impl_version to make CI happy * and revert back local test fixes * alter doc to restart CI * Transaction::clone() -> Transaction::duplicate() * transactions -> updated_tranasctions * remove explicit consensus-common ref * ::std:: -> std:: * manual set/unset flag -> calling clusore with given flag value * removed comments * removed force argument * BestIterator -> Box<Iterator> * separate crate for TxPool + Maintainer trait * long line fix * pos-merge fix * fix benches compilation * Rename txpoolapi to txpool_api * Clean up. * Finalize merge. * post-merge fix * Move transaction pool api to primitives directly. * Consistent naming for txpool-runtime-api * Warn about missing docs. * Move abstraction for offchain calls to tx-pool-api. * Merge RPC instantiation. * Update cargo.lock * Post merge fixes. * Avoid depending on client. * Fix build
This commit is contained in:
committed by
Gavin Wood
parent
3e26fceda4
commit
a782021ee8
@@ -34,7 +34,7 @@ pub enum Error {
|
||||
Client(Box<dyn std::error::Error + Send>),
|
||||
/// Transaction pool error,
|
||||
#[display(fmt="Transaction pool error: {}", _0)]
|
||||
Pool(txpool::error::Error),
|
||||
Pool(txpool_api::error::Error),
|
||||
/// Verification error
|
||||
#[display(fmt="Extrinsic verification error: {}", _0)]
|
||||
#[from(ignore)]
|
||||
@@ -93,7 +93,7 @@ const UNSUPPORTED_KEY_TYPE: i64 = POOL_INVALID_TX + 7;
|
||||
|
||||
impl From<Error> for rpc::Error {
|
||||
fn from(e: Error) -> Self {
|
||||
use txpool::error::{Error as PoolError};
|
||||
use txpool_api::error::{Error as PoolError};
|
||||
|
||||
match e {
|
||||
Error::BadFormat(e) => rpc::Error {
|
||||
|
||||
@@ -21,11 +21,9 @@ pub mod hash;
|
||||
|
||||
use jsonrpc_derive::rpc;
|
||||
use jsonrpc_pubsub::{typed::Subscriber, SubscriptionId};
|
||||
use primitives::{
|
||||
Bytes
|
||||
};
|
||||
use primitives::Bytes;
|
||||
use txpool_api::TransactionStatus;
|
||||
use self::error::{FutureResult, Result};
|
||||
use txpool::watcher::Status;
|
||||
|
||||
pub use self::gen_client::Client as AuthorClient;
|
||||
|
||||
@@ -69,7 +67,7 @@ pub trait AuthorApi<Hash, BlockHash> {
|
||||
)]
|
||||
fn watch_extrinsic(&self,
|
||||
metadata: Self::Metadata,
|
||||
subscriber: Subscriber<Status<Hash, BlockHash>>,
|
||||
subscriber: Subscriber<TransactionStatus<Hash, BlockHash>>,
|
||||
bytes: Bytes
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user