diff --git a/Cargo.lock b/Cargo.lock index de2da4587f..62f6e87982 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -871,7 +871,7 @@ dependencies = [ [[package]] name = "basilisk-runtime" -version = "110.0.0" +version = "111.0.0" dependencies = [ "cumulus-pallet-aura-ext", "cumulus-pallet-dmp-queue", @@ -900,7 +900,6 @@ dependencies = [ "orml-unknown-tokens", "orml-vesting", "orml-xcm", - "orml-xcm-builder-kusama", "orml-xcm-support", "orml-xtokens", "pallet-asset-registry", @@ -6281,26 +6280,6 @@ dependencies = [ "staging-xcm", ] -[[package]] -name = "orml-xcm-builder-kusama" -version = "1.0.0" -source = "git+https://github.com/open-web3-stack/orml-xcm-builder?rev=32f0b3f1cbe77d4d330e07c7d4fcc3ebd669db77#32f0b3f1cbe77d4d330e07c7d4fcc3ebd669db77" -dependencies = [ - "frame-support", - "frame-system", - "log", - "parity-scale-codec", - "scale-info", - "sp-arithmetic", - "sp-core", - "sp-io", - "sp-runtime", - "sp-std", - "sp-weights", - "staging-xcm", - "staging-xcm-executor", -] - [[package]] name = "orml-xcm-support" version = "0.4.1-dev" diff --git a/Cargo.toml b/Cargo.toml index 83922f852b..14ef6374fa 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -223,9 +223,6 @@ orml-xcm = { git = "https://github.com/open-web3-stack/open-runtime-module-libra orml-xcm-support = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "b3694e631df7f1ca16b1973122937753fcdee9d4", default-features = false } orml-xtokens = { git = "https://github.com/open-web3-stack/open-runtime-module-library", rev = "b3694e631df7f1ca16b1973122937753fcdee9d4", default-features = false } -# InvArch Tinkernet Multisig dependencies -orml-xcm-builder-kusama = { git = "https://github.com/open-web3-stack/orml-xcm-builder", rev = "32f0b3f1cbe77d4d330e07c7d4fcc3ebd669db77", default-features = false } - [patch."https://github.com/paritytech/polkadot-sdk"] frame-benchmarking = { git = "https://github.com/galacticcouncil/polkadot-sdk", rev = "062d92eae0f3bb9908faf2d4e241eef17368b9d3" } diff --git a/runtime/basilisk/Cargo.toml b/runtime/basilisk/Cargo.toml index 82c4cdc93a..70eda5f940 100644 --- a/runtime/basilisk/Cargo.toml +++ b/runtime/basilisk/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "basilisk-runtime" -version = "110.0.0" +version = "111.0.0" authors = ["GalacticCouncil"] edition = "2021" homepage = "https://github.com/galacticcouncil/Basilisk-node" @@ -125,9 +125,6 @@ sp-staking = { workspace = true } sp-trie = { workspace = true } sp-io = { workspace = true } -# InvArch Tinkernet Multisig dependencies -orml-xcm-builder-kusama = { workspace = true } - [features] default = ["std"] runtime-benchmarks = [ diff --git a/runtime/basilisk/src/lib.rs b/runtime/basilisk/src/lib.rs index 6656fe443f..df468dacc0 100644 --- a/runtime/basilisk/src/lib.rs +++ b/runtime/basilisk/src/lib.rs @@ -102,7 +102,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { spec_name: create_runtime_str!("basilisk"), impl_name: create_runtime_str!("basilisk"), authoring_version: 1, - spec_version: 110, + spec_version: 111, impl_version: 0, apis: RUNTIME_API_VERSIONS, transaction_version: 1, diff --git a/runtime/basilisk/src/xcm.rs b/runtime/basilisk/src/xcm.rs index 96a1459909..6defe9fb96 100644 --- a/runtime/basilisk/src/xcm.rs +++ b/runtime/basilisk/src/xcm.rs @@ -42,9 +42,9 @@ use primitives::AssetId; use scale_info::TypeInfo; use xcm_builder::{ AccountId32Aliases, AllowKnownQueryResponses, AllowSubscriptionsFrom, AllowTopLevelPaidExecutionFrom, - EnsureXcmOrigin, FixedWeightBounds, ParentIsPreset, RelayChainAsNative, SiblingParachainAsNative, - SiblingParachainConvertsVia, SignedAccountId32AsNative, SignedToAccountId32, SovereignSignedViaLocation, - TakeWeightCredit, WithComputedOrigin, + DescribeAllTerminal, DescribeFamily, EnsureXcmOrigin, FixedWeightBounds, HashedDescription, ParentIsPreset, + RelayChainAsNative, SiblingParachainAsNative, SiblingParachainConvertsVia, SignedAccountId32AsNative, + SignedToAccountId32, SovereignSignedViaLocation, TakeWeightCredit, WithComputedOrigin, }; use xcm_executor::{Config, XcmExecutor}; @@ -104,8 +104,6 @@ pub type XcmOriginToCallOrigin = ( SignedAccountId32AsNative, // Xcm origins can be represented natively under the Xcm pallet's Xcm origin. XcmPassthrough, - // Derives signed AccountId32 origins for Tinkernet multisigs. - orml_xcm_builder_kusama::TinkernetMultisigAsNativeOrigin, ); parameter_types! { @@ -370,6 +368,18 @@ pub type XcmRouter = ( XcmpQueue, ); +// TODO: Remove after upgrading to `polkadot-v1.2.0` and replace types from xcm-builder. +pub struct DescribeBodyTerminal; +impl xcm_builder::DescribeLocation for DescribeBodyTerminal { + fn describe_location(l: &MultiLocation) -> Option> { + match (l.parents, &l.interior) { + (0, X1(Plurality { id, part })) => Some((b"Body", id, part).encode()), + _ => None, + } + } +} +pub type DescribeAllTerminalAndBody = (DescribeAllTerminal, DescribeBodyTerminal); + /// Type for specifying how a `MultiLocation` can be converted into an `AccountId`. This is used /// when determining ownership of accounts for asset transacting and when attempting to use XCM /// `Transact` in order to determine the dispatch Origin. @@ -380,8 +390,9 @@ pub type LocationToAccountId = ( SiblingParachainConvertsVia, // Straight up local `AccountId32` origins just alias directly to `AccountId`. AccountId32Aliases, - // Mapping Tinkernet multisig to the correctly derived AccountId32. - orml_xcm_builder_kusama::TinkernetMultisigAsAccountId, + // TODO: Replace DescribeAllTerminalAndBody with DescribeAllTerminal after upgrading to `polkadot-v1.2.0`. + // Foreign locations alias into accounts according to a hash of their standard description. + HashedDescription>, ); parameter_types! {