We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 552fa1b commit a559691Copy full SHA for a559691
pallets/subtensor/src/subnets/weights.rs
@@ -262,7 +262,11 @@ impl<T: Config> Pallet<T> {
262
263
// 5. Retrieve or initialize the VecDeque of commits for the hotkey.
264
let cur_block = Self::get_current_block_as_u64();
265
- let cur_epoch = Self::get_epoch_index(netuid, cur_block);
+ let cur_epoch = match Self::should_run_epoch(netuid, commit_block) {
266
+ true => Self::get_epoch_index(netuid, cur_block).saturating_add(1),
267
+ false => Self::get_epoch_index(netuid, cur_block)
268
+ };
269
+
270
CRV3WeightCommits::<T>::try_mutate(netuid, cur_epoch, |commits| -> DispatchResult {
271
// 6. Verify that the number of unrevealed commits is within the allowed limit.
272
0 commit comments