diff --git a/pallets/subtensor/src/staking/stake_utils.rs b/pallets/subtensor/src/staking/stake_utils.rs index 1be858529d..6b0c4ddb90 100644 --- a/pallets/subtensor/src/staking/stake_utils.rs +++ b/pallets/subtensor/src/staking/stake_utils.rs @@ -59,7 +59,8 @@ impl Pallet { pub fn update_moving_price(netuid: u16) { let alpha: I96F32 = SubnetMovingAlpha::::get(); let minus_alpha: I96F32 = I96F32::saturating_from_num(1.0).saturating_sub(alpha); - let current_price: I96F32 = alpha.saturating_mul(Self::get_alpha_price(netuid)); + let current_price: I96F32 = alpha + .saturating_mul(Self::get_alpha_price(netuid).min(I96F32::saturating_from_num(1.0))); let current_moving: I96F32 = minus_alpha.saturating_mul(Self::get_moving_alpha_price(netuid)); let new_moving: I96F32 = current_price.saturating_add(current_moving); diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 26bf16206f..815beaeb44 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -229,7 +229,7 @@ pub const VERSION: RuntimeVersion = RuntimeVersion { // `spec_version`, and `authoring_version` are the same between Wasm and native. // This value is set to 100 to notify Polkadot-JS App (https://polkadot.js.org/apps) to use // the compatible custom types. - spec_version: 233, + spec_version: 234, impl_version: 1, apis: RUNTIME_API_VERSIONS, transaction_version: 1,