From 998123f5f380e669ce4b4fbad1a211d0f8719014 Mon Sep 17 00:00:00 2001 From: f-gate Date: Fri, 24 Nov 2023 09:50:48 +0000 Subject: [PATCH] fix xcm tranfers --- pallets/proposals/src/traits.rs | 6 +++--- runtime/imbue-kusama/src/lib.rs | 20 ------------------- runtime/integration-tests/Cargo.toml | 1 - .../integration-tests/src/xcm_transfers.rs | 2 +- 4 files changed, 4 insertions(+), 25 deletions(-) diff --git a/pallets/proposals/src/traits.rs b/pallets/proposals/src/traits.rs index ad232f39..8e0dc6db 100644 --- a/pallets/proposals/src/traits.rs +++ b/pallets/proposals/src/traits.rs @@ -14,7 +14,8 @@ pub trait IntoProposal { type MaximumContributorsPerProject: Get; type MaxMilestonesPerProject: Get; type MaxJuryMembers: Get; - /// Convert the propoerties of a project into a project. + + /// Convert the properties of a project into a project. /// This is the main method when wanting to use pallet_proposals and is how one configures a project. fn convert_to_proposal( currency_id: CurrencyId, @@ -27,7 +28,6 @@ pub trait IntoProposal { on_creation_funding: FundingPath, ) -> Result<(), DispatchError>; - /// Convert a btreemap of contributions to multilocations with the Here junction. /// Use when the contributors are the refund locations. fn convert_contributions_to_refund_locations( contributions: &BoundedBTreeMap, Self::MaximumContributorsPerProject>, @@ -62,7 +62,7 @@ impl ExternalRefundHandler, BalanceOf, Curre pub struct XcmRefundHandler(T, U); impl ExternalRefundHandler, T::Balance, CurrencyId> for XcmRefundHandler where - [u8; 32]: From>, + [u8; 32]: From>, T: orml_xtokens::Config, U: XcmTransfer, { diff --git a/runtime/imbue-kusama/src/lib.rs b/runtime/imbue-kusama/src/lib.rs index 69fcf5dc..464061bd 100644 --- a/runtime/imbue-kusama/src/lib.rs +++ b/runtime/imbue-kusama/src/lib.rs @@ -890,26 +890,6 @@ impl pallet_fellowship::Config for Runtime { type WeightInfo = pallet_fellowship::weights::WeightInfo; } -parameter_types! { - pub MaxCandidatesPerShortlist: u32 = 50; - pub ShortlistPeriod: BlockNumber = 14 * DAYS; - pub MembershipDeposit: Balance = DOLLARS.saturating_mul(500); - pub DepositCurrencyId: CurrencyId = CurrencyId::Native; -} - -impl pallet_fellowship::Config for Runtime { - type RuntimeEvent = RuntimeEvent; - type MultiCurrency = Currencies; - type ForceAuthority = EnsureRootOr; - type MaxCandidatesPerShortlist = MaxCandidatesPerShortlist; - type ShortlistPeriod = ShortlistPeriod; - type MembershipDeposit = MembershipDeposit; - type DepositCurrencyId = DepositCurrencyId; - // Send slashes to the treasury. - type SlashAccount = TreasuryAccount; - type Permissions = pallet_fellowship::impls::VetterAndFreelancerAllPermissions; - type WeightInfo = pallet_fellowship::weights::WeightInfo; -} pub type DepositId = u64; pub struct ImbueDepositCalculator; diff --git a/runtime/integration-tests/Cargo.toml b/runtime/integration-tests/Cargo.toml index 5c45fb10..22e9671e 100644 --- a/runtime/integration-tests/Cargo.toml +++ b/runtime/integration-tests/Cargo.toml @@ -88,7 +88,6 @@ std = [ "sp-io/std", ] runtime-benchmarks = [ - "default", "frame-benchmarking/runtime-benchmarks", "frame-support/runtime-benchmarks", "frame-system/runtime-benchmarks", diff --git a/runtime/integration-tests/src/xcm_transfers.rs b/runtime/integration-tests/src/xcm_transfers.rs index 2343002f..7623439e 100644 --- a/runtime/integration-tests/src/xcm_transfers.rs +++ b/runtime/integration-tests/src/xcm_transfers.rs @@ -161,7 +161,7 @@ fn test_xcm_refund_handler_to_kusama() { let ksm_balance = OrmlTokens::free_balance(CurrencyId::KSM, &DevelopmentReceiver::get()); assert!(ksm_balance > 0); assert_ok!( - ::RefundHandler::send_refund_message_to_treasury( + ::ExternalRefundHandler::send_refund_message_to_treasury( DevelopmentReceiver::get(), ksm_balance, CurrencyId::KSM,