Skip to content

Commit

Permalink
Merge branch 'main' into acceptable-payment-assets-in-asset-hubs
Browse files Browse the repository at this point in the history
  • Loading branch information
franciscoaguirre authored Jan 9, 2025
2 parents 339c39b + 80ac2e4 commit 5f6bdfd
Show file tree
Hide file tree
Showing 10 changed files with 32 additions and 17 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/check-migrations.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,10 @@ jobs:
# if they all pass, that job will pass too.
check-migrations:
needs: [runtime-matrix]
continue-on-error: true
runs-on: ubuntu-latest
strategy:
# Ensure the other jobs continue
fail-fast: false
matrix:
runtime: ${{ fromJSON(needs.runtime-matrix.outputs.runtime) }}
steps:
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Location conversion tests for relays and parachains ([polkadot-fellows/runtimes#487](https://github.com/polkadot-fellows/runtimes/pull/487))
- Asset Hubs: XcmPaymentApi now returns all assets in a pool with the native token as acceptable for fee payment ([polkadot-fellows/runtimes#523](https://github.com/polkadot-fellows/runtimes/pull/523))

- ParaRegistration proxy for Polkadot and Kusama ([polkadot-fellows/runtimes#520](https://github.com/polkadot-fellows/runtimes/pull/520))

### Changed

- Kusama Treasury: remove funding to the Kappa Sigma Mu Society and disable burn ([polkadot-fellows/runtimes#507](https://github.com/polkadot-fellows/runtimes/pull/507))
Expand Down
4 changes: 2 additions & 2 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ pallet-bridge-grandpa = { version = "0.18.0", default-features = false }
pallet-bridge-messages = { version = "0.18.0", default-features = false }
pallet-bridge-parachains = { version = "0.18.0", default-features = false }
pallet-bridge-relayers = { version = "0.18.0", default-features = false }
pallet-broker = { version = "0.17.0", default-features = false }
pallet-broker = { version = "0.17.2", default-features = false }
pallet-child-bounties = { version = "37.0.0", default-features = false }
pallet-collator-selection = { version = "19.0.0", default-features = false }
pallet-collective = { version = "38.0.0", default-features = false }
Expand Down
11 changes: 11 additions & 0 deletions relay/kusama/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1143,6 +1143,8 @@ pub enum ProxyType {
NominationPools,
#[codec(index = 9)]
Spokesperson,
#[codec(index = 10)]
ParaRegistration,
}

impl Default for ProxyType {
Expand Down Expand Up @@ -1247,6 +1249,15 @@ impl InstanceFilter<RuntimeCall> for ProxyType {
RuntimeCall::System(frame_system::Call::remark { .. }) |
RuntimeCall::System(frame_system::Call::remark_with_event { .. })
),
ProxyType::ParaRegistration => matches!(
c,
RuntimeCall::Registrar(paras_registrar::Call::reserve { .. }) |
RuntimeCall::Registrar(paras_registrar::Call::register { .. }) |
RuntimeCall::Utility(pallet_utility::Call::batch { .. }) |
RuntimeCall::Utility(pallet_utility::Call::batch_all { .. }) |
RuntimeCall::Utility(pallet_utility::Call::force_batch { .. }) |
RuntimeCall::Proxy(pallet_proxy::Call::remove_proxy { .. })
),
}
}
fn is_superset(&self, o: &Self) -> bool {
Expand Down
10 changes: 10 additions & 0 deletions relay/polkadot/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1007,6 +1007,7 @@ pub enum ProxyType {
CancelProxy = 6,
Auction = 7,
NominationPools = 8,
ParaRegistration = 9,
}

#[cfg(test)]
Expand Down Expand Up @@ -1121,6 +1122,15 @@ impl InstanceFilter<RuntimeCall> for ProxyType {
RuntimeCall::Registrar(..) |
RuntimeCall::Slots(..)
),
ProxyType::ParaRegistration => matches!(
c,
RuntimeCall::Registrar(paras_registrar::Call::reserve { .. }) |
RuntimeCall::Registrar(paras_registrar::Call::register { .. }) |
RuntimeCall::Utility(pallet_utility::Call::batch { .. }) |
RuntimeCall::Utility(pallet_utility::Call::batch_all { .. }) |
RuntimeCall::Utility(pallet_utility::Call::force_batch { .. }) |
RuntimeCall::Proxy(pallet_proxy::Call::remove_proxy { .. })
),
}
}
fn is_superset(&self, o: &Self) -> bool {
Expand Down
2 changes: 1 addition & 1 deletion system-parachains/coretime/coretime-kusama/src/coretime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,6 @@ impl pallet_broker::Config for Runtime {
type PalletId = BrokerPalletId;
type AdminOrigin = EnsureRoot<AccountId>;
type SovereignAccountOf = SovereignAccountOf;
type MaxAutoRenewals = ConstU32<0>;
type MaxAutoRenewals = ConstU32<100>;
type PriceAdapter = pallet_broker::CenterTargetPrice<Balance>;
}
8 changes: 1 addition & 7 deletions system-parachains/coretime/coretime-kusama/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -186,16 +186,10 @@ parameter_types! {
/// Filter:
/// - Credit purchase calls until the credit system is implemented. Otherwise, users may have chance
/// of locking their funds forever on purchased credits they cannot use.
/// - Auto-renew functionality until resolution of polkadot-sdk issue [#6474](https://github.com/paritytech/polkadot-sdk/issues/6474)
pub struct IsFilteredBrokerCall;
impl Contains<RuntimeCall> for IsFilteredBrokerCall {
fn contains(c: &RuntimeCall) -> bool {
matches!(
c,
RuntimeCall::Broker(pallet_broker::Call::purchase_credit { .. }) |
RuntimeCall::Broker(pallet_broker::Call::enable_auto_renew { .. }) |
RuntimeCall::Broker(pallet_broker::Call::disable_auto_renew { .. })
)
matches!(c, RuntimeCall::Broker(pallet_broker::Call::purchase_credit { .. }))
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,6 @@ impl pallet_broker::Config for Runtime {
type PalletId = BrokerPalletId;
type AdminOrigin = EnsureRoot<AccountId>;
type SovereignAccountOf = SovereignAccountOf;
type MaxAutoRenewals = ConstU32<0>;
type MaxAutoRenewals = ConstU32<100>;
type PriceAdapter = pallet_broker::CenterTargetPrice<Balance>;
}
5 changes: 1 addition & 4 deletions system-parachains/coretime/coretime-polkadot/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,16 +184,13 @@ parameter_types! {
/// - Credit purchase calls until the credit system is implemented. Otherwise, users may have chance
/// of locking their funds forever on purchased credits they cannot use.
/// - The interlace call until the relay can support this fully
/// - Auto-renew functionality until resolution of polkadot-sdk issue [#6474](https://github.com/paritytech/polkadot-sdk/issues/6474)
pub struct IsFilteredBrokerCall;
impl Contains<RuntimeCall> for IsFilteredBrokerCall {
fn contains(c: &RuntimeCall) -> bool {
matches!(
c,
RuntimeCall::Broker(pallet_broker::Call::purchase_credit { .. }) |
RuntimeCall::Broker(pallet_broker::Call::interlace { .. }) |
RuntimeCall::Broker(pallet_broker::Call::enable_auto_renew { .. }) |
RuntimeCall::Broker(pallet_broker::Call::disable_auto_renew { .. })
RuntimeCall::Broker(pallet_broker::Call::interlace { .. })
)
}
}
Expand Down

0 comments on commit 5f6bdfd

Please sign in to comment.