Follow-up for dynamic tempo - removing deprecated activity cutoff#2774
Follow-up for dynamic tempo - removing deprecated activity cutoff#2774evgeny-s wants to merge 10 commits into
Conversation
eco-tests changed — indexer review requiredThis PR modifies files under Changed files
|
🛡️ AI Review — Skeptic (security review)VERDICT: SAFE BASELINE scrutiny: established 2012 account with repository write permission and substantial subtensor PR history; no Gittensor allowlist/index hit; branch chore/dynamic-tempo-cleanup -> devnet-ready. Static review found no protected FindingsNo findings. ConclusionNo malicious intent or security vulnerability was identified in the reviewed diff. The migration ordering, storage cleanup, API removal, and runtime proxy update are consistent with the prior dynamic-tempo migration model. 🔍 AI Review — Auditor (domain review)VERDICT: 👍 Gittensor: LIKELY by heuristic; author has write permission and substantial recent Subtensor PR activity, with no direct allowlist/index hit. Static review covered the legacy
FindingsNo findings. ConclusionApproving: the cleanup is coherent, migration ordering preserves the dynamic-tempo conversion path, and the new storage cleanup is covered by focused migration tests. The PR body’s “merge after dynamic tempo mainnet release” note remains a human merge-timing constraint, not a code finding. |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
# Conflicts: # pallets/admin-utils/src/weights.rs
| fn sudo_set_difficulty() -> Weight; | ||
| fn sudo_set_adjustment_interval() -> Weight; | ||
| fn sudo_set_target_registrations_per_interval() -> Weight; | ||
| fn sudo_set_activity_cutoff() -> Weight; |
There was a problem hiding this comment.
[HIGH] Remove the stale generated weight implementations too
Deleting this trait item leaves two generated sudo_set_activity_cutoff() implementations in this same file, around pallets/admin-utils/src/weights.rs:367 and pallets/admin-utils/src/weights.rs:1333. Those methods are no longer members of WeightInfo, and Rust trait impls cannot define extra associated methods, so pallet-admin-utils will not compile after this cleanup. Regenerate pallets/admin-utils/src/weights.rs or manually remove both stale method blocks along with this trait item.
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👎 |
| fn sudo_trim_to_max_allowed_uids() -> Weight; | ||
| fn sudo_set_min_non_immune_uids() -> Weight; | ||
| fn sudo_set_max_epochs_per_block() -> Weight; | ||
| fn sudo_set_activity_cutoff() -> Weight; |
There was a problem hiding this comment.
[LOW] Remove the stale generated activity-cutoff weight stub
sudo_set_activity_cutoff was removed from pallets/admin-utils/src/lib.rs and its benchmark was deleted, but the generated WeightInfo trait still exposes the method and both generated impls still define it against the removed SubtensorModule::ActivityCutoff / MinActivityCutoff storage. This no longer appears to be the compile-breaking mismatch from the prior run because the trait and impls are internally consistent, but it leaves dead generated weight code for an extrinsic this PR removes. Regenerate pallets/admin-utils/src/weights.rs or delete the stale trait item and the two sudo_set_activity_cutoff impl blocks.
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
# Conflicts: # contract-tests/src/contracts/subnet.ts # contract-tests/src/subtensor.ts # contract-tests/test/staking.precompile.reward.test.ts
| fn sudo_trim_to_max_allowed_uids() -> Weight; | ||
| fn sudo_set_min_non_immune_uids() -> Weight; | ||
| fn sudo_set_max_epochs_per_block() -> Weight; | ||
| fn sudo_set_activity_cutoff() -> Weight; |
There was a problem hiding this comment.
[LOW] Remove the stale generated activity-cutoff weight stub
sudo_set_activity_cutoff was removed from pallets/admin-utils/src/lib.rs, but this generated weight method is still re-added to the trait and the file still carries both impl bodies for the removed call. This is dead generated code over storage that the PR deletes; regenerate pallet_admin_utils weights or remove the trait method and both impl methods so the weights file matches the pallet surface.
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
|
🔄 AI review updated — Skeptic: SAFE Auditor: 👍 |
Description
Follow-up PR for #2638:
Related Issue(s)
Type of Change
Breaking Change
If this PR introduces a breaking change, please provide a detailed description of the impact and the migration path for existing applications.
Checklist
./scripts/fix_rust.shto ensure my code is formatted and linted correctlyScreenshots (if applicable)
Please include any relevant screenshots or GIFs that demonstrate the changes made.
Additional Notes
Please provide any additional information or context that may be helpful for reviewers.