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

Add MutatesHold trait to pallet asset #1

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
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
58 changes: 20 additions & 38 deletions Cargo.lock

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

Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,8 @@ impl pallet_assets::Config<TrustBackedAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -324,6 +326,8 @@ impl pallet_assets::Config<PoolAssetsInstance> for Runtime {
type Extra = ();
type WeightInfo = weights::pallet_assets_pool::WeightInfo<Runtime>;
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -398,6 +402,8 @@ impl pallet_assets::Config<ForeignAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = ForeignAssetsAssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = xcm_config::XcmBenchmarkHelper;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,8 @@ impl pallet_assets::Config<TrustBackedAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -336,6 +338,8 @@ impl pallet_assets::Config<ForeignAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = ForeignAssetsAssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = xcm_config::XcmBenchmarkHelper;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,8 @@ impl pallet_assets::Config<TrustBackedAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -321,6 +323,8 @@ impl pallet_assets::Config<PoolAssetsInstance> for Runtime {
type Extra = ();
type WeightInfo = weights::pallet_assets_pool::WeightInfo<Runtime>;
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -395,6 +399,8 @@ impl pallet_assets::Config<ForeignAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = ForeignAssetsAssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = xcm_config::XcmBenchmarkHelper;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,8 @@ impl pallet_assets::Config<TrustBackedAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -303,6 +305,8 @@ impl pallet_assets::Config<PoolAssetsInstance> for Runtime {
type Extra = ();
type WeightInfo = weights::pallet_assets_pool::WeightInfo<Runtime>;
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -376,6 +380,8 @@ impl pallet_assets::Config<ForeignAssetsInstance> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = ForeignAssetsAssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = xcm_config::XcmBenchmarkHelper;
}
Expand Down Expand Up @@ -1692,7 +1698,7 @@ pub mod migrations {
let pool_asset_id = pool_info.lp_token.clone();
if old_pool_id.0.as_ref() != &invalid_native_asset {
// skip, if ok
continue
continue;
}

// fix new account
Expand Down
2 changes: 2 additions & 0 deletions cumulus/parachains/runtimes/testing/penpal/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,8 @@ impl pallet_assets::Config<pallet_assets::Instance1> for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -576,6 +576,8 @@ impl pallet_assets::Config for Runtime {
type CallbackHandle = ();
type AssetAccountDeposit = AssetAccountDeposit;
type RemoveItemsLimit = frame_support::traits::ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down
2 changes: 2 additions & 0 deletions polkadot/xcm/xcm-builder/src/tests/pay/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,8 @@ impl pallet_assets::Config for Test {
type RemoveItemsLimit = RemoveItemsLimit;
type AssetIdParameter = AssetIdForAssets;
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down
4 changes: 4 additions & 0 deletions substrate/bin/node/runtime/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1613,6 +1613,8 @@ impl pallet_assets::Config<Instance1> for Runtime {
type CallbackHandle = ();
type WeightInfo = pallet_assets::weights::SubstrateWeight<Runtime>;
type RemoveItemsLimit = ConstU32<1000>;
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down Expand Up @@ -1640,6 +1642,8 @@ impl pallet_assets::Config<Instance2> for Runtime {
type WeightInfo = pallet_assets::weights::SubstrateWeight<Runtime>;
type RemoveItemsLimit = ConstU32<1000>;
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
#[cfg(feature = "runtime-benchmarks")]
type BenchmarkHelper = ();
}
Expand Down
4 changes: 4 additions & 0 deletions substrate/frame/asset-conversion/src/mock.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,8 @@ impl pallet_assets::Config<Instance1> for Test {
type Extra = ();
type WeightInfo = ();
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
pallet_assets::runtime_benchmarks_enabled! {
type BenchmarkHelper = ();
}
Expand All @@ -135,6 +137,8 @@ impl pallet_assets::Config<Instance2> for Test {
type Extra = ();
type WeightInfo = ();
type CallbackHandle = ();
type MaxHolds = ConstU32<50>;
type RuntimeHoldReason = RuntimeHoldReason;
pallet_assets::runtime_benchmarks_enabled! {
type BenchmarkHelper = ();
}
Expand Down
Loading
Loading