Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix xcm config for coretime. #3768

Merged
merged 7 commits into from
Mar 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions polkadot/runtime/westend/src/xcm_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ use xcm_builder::{
AccountId32Aliases, AllowExplicitUnpaidExecutionFrom, AllowKnownQueryResponses,
AllowSubscriptionsFrom, AllowTopLevelPaidExecutionFrom, ChildParachainAsNative,
ChildParachainConvertsVia, DescribeAllTerminal, DescribeFamily, FrameTransactionalProcessor,
FungibleAdapter, HashedDescription, IsConcrete, MintLocation, OriginToPluralityVoice,
SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit,
TrailingSetTopicAsId, UsingComponents, WeightInfoBounds, WithComputedOrigin, WithUniqueTopic,
XcmFeeManagerFromComponents, XcmFeeToAccount,
FungibleAdapter, HashedDescription, IsChildSystemParachain, IsConcrete, MintLocation,
OriginToPluralityVoice, SignedAccountId32AsNative, SignedToAccountId32,
SovereignSignedViaLocation, TakeWeightCredit, TrailingSetTopicAsId, UsingComponents,
WeightInfoBounds, WithComputedOrigin, WithUniqueTopic, XcmFeeManagerFromComponents,
XcmFeeToAccount,
};
use xcm_executor::XcmExecutor;

Expand Down Expand Up @@ -142,13 +143,12 @@ impl Contains<Location> for OnlyParachains {
}
}

pub struct CollectivesOrFellows;
impl Contains<Location> for CollectivesOrFellows {
pub struct Fellows;
impl Contains<Location> for Fellows {
fn contains(location: &Location) -> bool {
matches!(
location.unpack(),
(0, [Parachain(COLLECTIVES_ID)]) |
(0, [Parachain(COLLECTIVES_ID), Plurality { id: BodyId::Technical, .. }])
(0, [Parachain(COLLECTIVES_ID), Plurality { id: BodyId::Technical, .. }])
)
}
}
Expand All @@ -172,8 +172,8 @@ pub type Barrier = TrailingSetTopicAsId<(
AllowTopLevelPaidExecutionFrom<Everything>,
// Subscriptions for version tracking are OK.
AllowSubscriptionsFrom<OnlyParachains>,
// Collectives and Fellows plurality get free execution.
AllowExplicitUnpaidExecutionFrom<CollectivesOrFellows>,
// Messages from system parachains or the Fellows plurality need not pay for execution.
AllowExplicitUnpaidExecutionFrom<(IsChildSystemParachain<ParaId>, Fellows)>,
),
UniversalLocation,
ConstU32<8>,
Expand Down
Loading