Support dynamic tempo#3383
Open
basfroman wants to merge 19 commits into
Open
Conversation
thewhaleking
approved these changes
Jun 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds SDK support for the new stateful epoch model introduced in subtensor.
AC for merge:
bittensor-drand v2.0.0releasedbittensor-drandupdated in SDK dependency inpyproject.tomlfileIncludes:
Storage getters
get_last_epoch_blockget_pending_epoch_atget_subnet_epoch_indexget_activity_cutoff_factor_milliget_owner_hyperparam_rate_limitget_epoch_schedule_state.Extrinsics
set_temposet_activity_cutoff_factorroot_set_activity_cutoff_factortrigger_epoch.Details
blocks_until_next_epochandget_next_epoch_start_blocknow delegate to theSubnetInfoRuntimeApiruntime API instead of local modulo arithmetic. Thetempoparameter is removed fromblocks_until_next_epoch.commit_timelocked_weights_extrinsicmigrated fromget_encrypted_committoget_encrypted_commit_v2which takesEpochScheduleStatefor epoch prediction.SubnetHyperparametersrefactored to a hybrid container that supports v1/v2/v3 chain formats viafrom_any. Unknown fields spill intohyperparametersdict. Addedactivity_cutoff_factorfield.activity_cutoffis nowOptional[int].New entries:
EpochScheduleStatedataclass intypes.py.epoch_scheduleutility module withblocks_until_next_auto_epochandis_in_admin_freeze_window.Breaking changes:
bittensor-drand>=2.0.0.Subtensor.blocks_until_next_epochandAsyncSubtensor.blocks_until_next_epoch:blockis now keyword-only. Callers passing it positionally must update toblocks_until_next_epoch(netuid, block=N).Related links: