mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 18:41:03 +00:00
Fix delivery transaction estimation used by rational relayer (#1109)
* fix delivery transaction estimation in greedy relayer * fixed typo * improve logging * improve logging * fmt * fix compilation * fmt * Update relays/lib-substrate-relay/src/messages_target.rs Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com> * review Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
This commit is contained in:
committed by
Bastian Köcher
parent
2101ed9cc5
commit
03a54df398
@@ -15,7 +15,7 @@
|
||||
// along with Parity Bridges Common. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
use bp_runtime::Chain as ChainBase;
|
||||
use frame_support::Parameter;
|
||||
use frame_support::{weights::WeightToFeePolynomial, Parameter};
|
||||
use jsonrpsee_ws_client::{DeserializeOwned, Serialize};
|
||||
use num_traits::{Bounded, CheckedSub, SaturatingAdd, Zero};
|
||||
use sp_core::{storage::StorageKey, Pair};
|
||||
@@ -77,12 +77,17 @@ pub trait Chain: ChainBase + Clone {
|
||||
+ SaturatingAdd
|
||||
+ Zero
|
||||
+ std::convert::TryFrom<sp_core::U256>;
|
||||
|
||||
/// Type that is used by the chain, to convert from weight to fee.
|
||||
type WeightToFee: WeightToFeePolynomial<Balance = Self::Balance>;
|
||||
}
|
||||
|
||||
/// Balance type used by the chain
|
||||
pub type BalanceOf<C> = <C as Chain>::Balance;
|
||||
/// Index type used by the chain
|
||||
pub type IndexOf<C> = <C as Chain>::Index;
|
||||
/// Weight-to-Fee type used by the chain
|
||||
pub type WeightToFeeOf<C> = <C as Chain>::WeightToFee;
|
||||
|
||||
/// Substrate-based chain with `frame_system::Config::AccountData` set to
|
||||
/// the `pallet_balances::AccountData<Balance>`.
|
||||
|
||||
Reference in New Issue
Block a user