Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Substrate 13843 (Asset Freezing) Companion (#2437)
Browse files Browse the repository at this point in the history
* add migrations

* fix pallet instancing in migration

* migrate by instance

* weights

* remove migrations

* update weights

* update weights

* update lockfile for {"polkadot", "substrate"}

---------

Co-authored-by: muharem <[email protected]>
Co-authored-by: parity-processbot <>
  • Loading branch information
2 people authored and EgorPopelyaev committed May 11, 2023
1 parent 075a430 commit e937144
Show file tree
Hide file tree
Showing 3 changed files with 207 additions and 0 deletions.
69 changes: 69 additions & 0 deletions parachains/runtimes/assets/statemine/src/weights/pallet_assets.rs
Original file line number Diff line number Diff line change
Expand Up @@ -441,4 +441,73 @@ impl<T: frame_system::Config> pallet_assets::WeightInfo for WeightInfo<T> {
.saturating_add(T::DbWeight::get().reads(1))
.saturating_add(T::DbWeight::get().writes(1))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn touch() -> Weight {
// Proof Size summary in bytes:
// Measured: `453`
// Estimated: `3675`
// Minimum execution time: 37_468_000 picoseconds.
Weight::from_parts(37_957_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn touch_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `351`
// Estimated: `3675`
// Minimum execution time: 383_408_000 picoseconds.
Weight::from_parts(392_036_000, 3675)
.saturating_add(T::DbWeight::get().reads(2))
.saturating_add(T::DbWeight::get().writes(2))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn refund() -> Weight {
// Proof Size summary in bytes:
// Measured: `579`
// Estimated: `3675`
// Minimum execution time: 34_066_000 picoseconds.
Weight::from_parts(34_347_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn refund_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `510`
// Estimated: `3675`
// Minimum execution time: 32_060_000 picoseconds.
Weight::from_parts(32_519_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(2_u64))
}
/// Storage: Assets Asset (r:1 w:0)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
fn block() -> Weight {
// Proof Size summary in bytes:
// Measured: `459`
// Estimated: `3675`
// Minimum execution time: 115_000_000 picoseconds.
Weight::from_parts(163_000_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(1_u64))
}
}
69 changes: 69 additions & 0 deletions parachains/runtimes/assets/statemint/src/weights/pallet_assets.rs
Original file line number Diff line number Diff line change
Expand Up @@ -444,4 +444,73 @@ impl<T: frame_system::Config> pallet_assets::WeightInfo for WeightInfo<T> {
.saturating_add(T::DbWeight::get().reads(1))
.saturating_add(T::DbWeight::get().writes(1))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn touch() -> Weight {
// Proof Size summary in bytes:
// Measured: `453`
// Estimated: `3675`
// Minimum execution time: 37_468_000 picoseconds.
Weight::from_parts(37_957_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn touch_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `351`
// Estimated: `3675`
// Minimum execution time: 383_408_000 picoseconds.
Weight::from_parts(392_036_000, 3675)
.saturating_add(T::DbWeight::get().reads(2))
.saturating_add(T::DbWeight::get().writes(2))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn refund() -> Weight {
// Proof Size summary in bytes:
// Measured: `579`
// Estimated: `3675`
// Minimum execution time: 34_066_000 picoseconds.
Weight::from_parts(34_347_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn refund_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `510`
// Estimated: `3675`
// Minimum execution time: 32_060_000 picoseconds.
Weight::from_parts(32_519_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(2_u64))
}
/// Storage: Assets Asset (r:1 w:0)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
fn block() -> Weight {
// Proof Size summary in bytes:
// Measured: `459`
// Estimated: `3675`
// Minimum execution time: 115_000_000 picoseconds.
Weight::from_parts(163_000_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(1_u64))
}
}
69 changes: 69 additions & 0 deletions parachains/runtimes/assets/westmint/src/weights/pallet_assets.rs
Original file line number Diff line number Diff line change
Expand Up @@ -443,4 +443,73 @@ impl<T: frame_system::Config> pallet_assets::WeightInfo for WeightInfo<T> {
.saturating_add(T::DbWeight::get().reads(1))
.saturating_add(T::DbWeight::get().writes(1))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn touch() -> Weight {
// Proof Size summary in bytes:
// Measured: `453`
// Estimated: `3675`
// Minimum execution time: 37_468_000 picoseconds.
Weight::from_parts(37_957_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn touch_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `351`
// Estimated: `3675`
// Minimum execution time: 383_408_000 picoseconds.
Weight::from_parts(392_036_000, 3675)
.saturating_add(T::DbWeight::get().reads(2))
.saturating_add(T::DbWeight::get().writes(2))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: System Account (r:1 w:1)
/// Proof: System Account (max_values: None, max_size: Some(128), added: 2603, mode: MaxEncodedLen)
fn refund() -> Weight {
// Proof Size summary in bytes:
// Measured: `579`
// Estimated: `3675`
// Minimum execution time: 34_066_000 picoseconds.
Weight::from_parts(34_347_000, 3675)
.saturating_add(T::DbWeight::get().reads(3_u64))
.saturating_add(T::DbWeight::get().writes(3_u64))
}
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
/// Storage: Assets Asset (r:1 w:1)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
fn refund_other() -> Weight {
// Proof Size summary in bytes:
// Measured: `510`
// Estimated: `3675`
// Minimum execution time: 32_060_000 picoseconds.
Weight::from_parts(32_519_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(2_u64))
}
/// Storage: Assets Asset (r:1 w:0)
/// Proof: Assets Asset (max_values: None, max_size: Some(210), added: 2685, mode: MaxEncodedLen)
/// Storage: Assets Account (r:1 w:1)
/// Proof: Assets Account (max_values: None, max_size: Some(134), added: 2609, mode: MaxEncodedLen)
fn block() -> Weight {
// Proof Size summary in bytes:
// Measured: `459`
// Estimated: `3675`
// Minimum execution time: 115_000_000 picoseconds.
Weight::from_parts(163_000_000, 3675)
.saturating_add(T::DbWeight::get().reads(2_u64))
.saturating_add(T::DbWeight::get().writes(1_u64))
}
}

0 comments on commit e937144

Please sign in to comment.