mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-30 22:11:02 +00:00
Various nits and alignments for SP testnets found during bumping polkadot-fellows repo (#3359)
This commit is contained in:
@@ -73,8 +73,6 @@ use testnet_parachains_constants::rococo::{
|
|||||||
consensus::*, currency::*, fee::WeightToFee, snowbridge::INBOUND_QUEUE_PALLET_INDEX, time::*,
|
consensus::*, currency::*, fee::WeightToFee, snowbridge::INBOUND_QUEUE_PALLET_INDEX, time::*,
|
||||||
};
|
};
|
||||||
|
|
||||||
#[cfg(feature = "runtime-benchmarks")]
|
|
||||||
use bp_runtime::Chain;
|
|
||||||
use bp_runtime::HeaderId;
|
use bp_runtime::HeaderId;
|
||||||
use bridge_hub_common::{
|
use bridge_hub_common::{
|
||||||
message_queue::{NarrowOriginToSibling, ParaIdToSibling},
|
message_queue::{NarrowOriginToSibling, ParaIdToSibling},
|
||||||
@@ -1298,7 +1296,7 @@ impl_runtime_apis! {
|
|||||||
impl BridgeMessagesConfig<bridge_to_westend_config::WithBridgeHubWestendMessagesInstance> for Runtime {
|
impl BridgeMessagesConfig<bridge_to_westend_config::WithBridgeHubWestendMessagesInstance> for Runtime {
|
||||||
fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool {
|
fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool {
|
||||||
let bench_lane_id = <Self as BridgeMessagesConfig<bridge_to_westend_config::WithBridgeHubWestendMessagesInstance>>::bench_lane_id();
|
let bench_lane_id = <Self as BridgeMessagesConfig<bridge_to_westend_config::WithBridgeHubWestendMessagesInstance>>::bench_lane_id();
|
||||||
let bridged_chain_id = bp_bridge_hub_westend::BridgeHubWestend::ID;
|
let bridged_chain_id = bridge_to_westend_config::BridgeHubWestendChainId::get();
|
||||||
pallet_bridge_relayers::Pallet::<Runtime>::relayer_reward(
|
pallet_bridge_relayers::Pallet::<Runtime>::relayer_reward(
|
||||||
relayer,
|
relayer,
|
||||||
bp_relayers::RewardsAccountParams::new(
|
bp_relayers::RewardsAccountParams::new(
|
||||||
|
|||||||
@@ -69,8 +69,6 @@ pub use sp_consensus_aura::sr25519::AuthorityId as AuraId;
|
|||||||
pub use sp_runtime::{MultiAddress, Perbill, Permill};
|
pub use sp_runtime::{MultiAddress, Perbill, Permill};
|
||||||
use xcm_config::{XcmOriginToTransactDispatchOrigin, XcmRouter};
|
use xcm_config::{XcmOriginToTransactDispatchOrigin, XcmRouter};
|
||||||
|
|
||||||
#[cfg(feature = "runtime-benchmarks")]
|
|
||||||
use bp_runtime::Chain;
|
|
||||||
use bp_runtime::HeaderId;
|
use bp_runtime::HeaderId;
|
||||||
|
|
||||||
#[cfg(any(feature = "std", test))]
|
#[cfg(any(feature = "std", test))]
|
||||||
@@ -991,7 +989,7 @@ impl_runtime_apis! {
|
|||||||
impl BridgeMessagesConfig<bridge_to_rococo_config::WithBridgeHubRococoMessagesInstance> for Runtime {
|
impl BridgeMessagesConfig<bridge_to_rococo_config::WithBridgeHubRococoMessagesInstance> for Runtime {
|
||||||
fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool {
|
fn is_relayer_rewarded(relayer: &Self::AccountId) -> bool {
|
||||||
let bench_lane_id = <Self as BridgeMessagesConfig<bridge_to_rococo_config::WithBridgeHubRococoMessagesInstance>>::bench_lane_id();
|
let bench_lane_id = <Self as BridgeMessagesConfig<bridge_to_rococo_config::WithBridgeHubRococoMessagesInstance>>::bench_lane_id();
|
||||||
let bridged_chain_id = bp_bridge_hub_rococo::BridgeHubRococo::ID;
|
let bridged_chain_id = bridge_to_rococo_config::BridgeHubRococoChainId::get();
|
||||||
pallet_bridge_relayers::Pallet::<Runtime>::relayer_reward(
|
pallet_bridge_relayers::Pallet::<Runtime>::relayer_reward(
|
||||||
relayer,
|
relayer,
|
||||||
bp_relayers::RewardsAccountParams::new(
|
bp_relayers::RewardsAccountParams::new(
|
||||||
|
|||||||
@@ -27,7 +27,8 @@ use pallet_xcm::XcmPassthrough;
|
|||||||
use parachains_common::{
|
use parachains_common::{
|
||||||
impls::ToStakingPot,
|
impls::ToStakingPot,
|
||||||
xcm_config::{
|
xcm_config::{
|
||||||
AllSiblingSystemParachains, ConcreteAssetFromSystem, RelayOrOtherSystemParachains,
|
AllSiblingSystemParachains, ConcreteAssetFromSystem, ParentRelayOrSiblingParachains,
|
||||||
|
RelayOrOtherSystemParachains,
|
||||||
},
|
},
|
||||||
TREASURY_PALLET_ID,
|
TREASURY_PALLET_ID,
|
||||||
};
|
};
|
||||||
@@ -147,13 +148,6 @@ impl Contains<Location> for ParentOrParentsPlurality {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub struct ParentOrSiblings;
|
|
||||||
impl Contains<Location> for ParentOrSiblings {
|
|
||||||
fn contains(location: &Location) -> bool {
|
|
||||||
matches!(location.unpack(), (1, []) | (1, [Parachain(_)]))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/// A call filter for the XCM Transact instruction. This is a temporary measure until we properly
|
/// A call filter for the XCM Transact instruction. This is a temporary measure until we properly
|
||||||
/// account for proof size weights.
|
/// account for proof size weights.
|
||||||
///
|
///
|
||||||
@@ -219,7 +213,7 @@ pub type Barrier = TrailingSetTopicAsId<
|
|||||||
// Parent and its pluralities (i.e. governance bodies) get free execution.
|
// Parent and its pluralities (i.e. governance bodies) get free execution.
|
||||||
AllowExplicitUnpaidExecutionFrom<ParentOrParentsPlurality>,
|
AllowExplicitUnpaidExecutionFrom<ParentOrParentsPlurality>,
|
||||||
// Subscriptions for version tracking are OK.
|
// Subscriptions for version tracking are OK.
|
||||||
AllowSubscriptionsFrom<ParentOrSiblings>,
|
AllowSubscriptionsFrom<ParentRelayOrSiblingParachains>,
|
||||||
),
|
),
|
||||||
UniversalLocation,
|
UniversalLocation,
|
||||||
ConstU32<8>,
|
ConstU32<8>,
|
||||||
|
|||||||
@@ -27,7 +27,8 @@ use pallet_xcm::XcmPassthrough;
|
|||||||
use parachains_common::{
|
use parachains_common::{
|
||||||
impls::ToStakingPot,
|
impls::ToStakingPot,
|
||||||
xcm_config::{
|
xcm_config::{
|
||||||
AllSiblingSystemParachains, ConcreteAssetFromSystem, RelayOrOtherSystemParachains,
|
AllSiblingSystemParachains, ConcreteAssetFromSystem, ParentRelayOrSiblingParachains,
|
||||||
|
RelayOrOtherSystemParachains,
|
||||||
},
|
},
|
||||||
TREASURY_PALLET_ID,
|
TREASURY_PALLET_ID,
|
||||||
};
|
};
|
||||||
@@ -147,13 +148,6 @@ impl Contains<Location> for ParentOrParentsPlurality {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub struct ParentOrSiblings;
|
|
||||||
impl Contains<Location> for ParentOrSiblings {
|
|
||||||
fn contains(location: &Location) -> bool {
|
|
||||||
matches!(location.unpack(), (1, []) | (1, [Parachain(_)]))
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
pub struct FellowsPlurality;
|
pub struct FellowsPlurality;
|
||||||
impl Contains<Location> for FellowsPlurality {
|
impl Contains<Location> for FellowsPlurality {
|
||||||
fn contains(location: &Location) -> bool {
|
fn contains(location: &Location) -> bool {
|
||||||
@@ -227,7 +221,7 @@ pub type Barrier = TrailingSetTopicAsId<
|
|||||||
// get free execution.
|
// get free execution.
|
||||||
AllowExplicitUnpaidExecutionFrom<(ParentOrParentsPlurality, FellowsPlurality)>,
|
AllowExplicitUnpaidExecutionFrom<(ParentOrParentsPlurality, FellowsPlurality)>,
|
||||||
// Subscriptions for version tracking are OK.
|
// Subscriptions for version tracking are OK.
|
||||||
AllowSubscriptionsFrom<ParentOrSiblings>,
|
AllowSubscriptionsFrom<ParentRelayOrSiblingParachains>,
|
||||||
),
|
),
|
||||||
UniversalLocation,
|
UniversalLocation,
|
||||||
ConstU32<8>,
|
ConstU32<8>,
|
||||||
|
|||||||
Reference in New Issue
Block a user