mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-07-24 14:45:42 +00:00
Deprecate Weight::from_{ref_time, proof_size} (#13475)
* Deprecate Weight::from_{ref_time, proof_size}
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Update templates
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Use from_parts
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Use from_parts
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Dont revert comment 🤦
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* ".git/.scripts/commands/bench/bench.sh" pallet dev pallet_balances
* Update weight files
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* More fixes
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
* Adapt to Master changes
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
---------
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: command-bot <>
This commit is contained in:
committed by
GitHub
parent
7981d4aa59
commit
9e56e1acdd
@@ -363,11 +363,12 @@ impl MinerConfig for Runtime {
|
||||
|
||||
fn solution_weight(v: u32, t: u32, a: u32, d: u32) -> Weight {
|
||||
match MockWeightInfo::get() {
|
||||
MockedWeightInfo::Basic => Weight::from_ref_time(
|
||||
MockedWeightInfo::Basic => Weight::from_parts(
|
||||
(10 as u64).saturating_add((5 as u64).saturating_mul(a as u64)),
|
||||
0,
|
||||
),
|
||||
MockedWeightInfo::Complex =>
|
||||
Weight::from_ref_time((0 * v + 0 * t + 1000 * a + 0 * d) as u64),
|
||||
Weight::from_parts((0 * v + 0 * t + 1000 * a + 0 * d) as u64, 0),
|
||||
MockedWeightInfo::Real =>
|
||||
<() as multi_phase::weights::WeightInfo>::feasibility_check(v, t, a, d),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user