Skip to content

Adapt rate limits after disabling in-block staking rate limit#2720

Merged
open-junius merged 1 commit into
devnet-readyfrom
chore/adapt-rate-limits
Jun 5, 2026
Merged

Adapt rate limits after disabling in-block staking rate limit#2720
open-junius merged 1 commit into
devnet-readyfrom
chore/adapt-rate-limits

Conversation

@evgeny-s
Copy link
Copy Markdown
Collaborator

@evgeny-s evgeny-s commented Jun 5, 2026

Description

Follow-up PR to adapt rate limits after merging:

Related Issue(s)

  • Closes #[issue number]

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Other (please describe):

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

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have run ./scripts/fix_rust.sh to ensure my code is formatted and linted correctly
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

Screenshots (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.

@evgeny-s evgeny-s added the skip-cargo-audit This PR fails cargo audit but needs to be merged anyway label Jun 5, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 5, 2026

🛡️ AI Review — Skeptic (security review)

VERDICT: SAFE

Baseline scrutiny: evgeny-s has write permission, a long-lived account with substantial contribution history, no Gittensor allowlist hit found; branch chore/adapt-rate-limits targets expected base devnet-ready.

Static review only. The PR changes a single pallet file, does not touch .github/, dependencies, build scripts, origin checks, or storage migrations. The diff removes stale staking-operation-limiter calls from the order-swap adapter after the underlying limiter/helper API was already removed on the base line.

Findings

No findings.

Conclusion

No malicious behavior or security vulnerability found in this diff. The remaining change is narrow cleanup around rate-limit removal and does not introduce a new unchecked user-controlled path, panic source, or supply-chain risk.


🔍 AI Review — Auditor (domain review)

VERDICT: 👍

Gittensor UNKNOWN; author has repo write permission, a long-lived GitHub account, and substantial prior subtensor activity, so review focused on correctness and duplicate-work risk.

The Auditor proposed a replacement PR description, but the current body is non-trivial; not overwriting. Maintainers: ask the Auditor to regenerate if you want it.

No actionable domain findings.

Duplicate-work check: PR #2720 is the better candidate for this narrow rate-limit adaptation. Recommend closing #2719 because it carries the same functional order_swap.rs change plus an unconditional spec_version bump; the bump should be applied only if the devnet spec-version check requires it. Recommend keeping this change separate from #2716, which bundles the same edit into unrelated TypeScript E2E migration work. #2685 did not show a current comparable order_swap.rs diff in the local refs.

Verification: git diff --check passed. A targeted SKIP_WASM_BUILD=1 cargo check -p pallet-subtensor could not start because rustup attempted to write under read-only /home/runner/.rustup. The devnet runtime-version query also could not run in this sandbox because DNS resolution for dev.chain.opentensor.ai failed, so no spec-version auto-fix was applied.

Findings

No findings.

Conclusion

The implementation is a small, consistent follow-up to the removed staking operation limiter: it drops now-obsolete rate-limit calls while preserving subnet existence, subtoken, hotkey, balance, lock, slippage, and stake-availability checks. I do not see a correctness blocker in the changed code.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 5, 2026

🔄 AI review updated — Skeptic: SAFE Auditor: 👍

@open-junius open-junius mentioned this pull request Jun 5, 2026
13 tasks
@open-junius open-junius merged commit 3c0a134 into devnet-ready Jun 5, 2026
410 of 421 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-cargo-audit This PR fails cargo audit but needs to be merged anyway

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants