Skip to content

add SetRootWeights proxy - #3132

Open
UnArbosSix wants to merge 1 commit into
mainfrom
add-set-root-weights-proxy
Open

add SetRootWeights proxy#3132
UnArbosSix wants to merge 1 commit into
mainfrom
add-set-root-weights-proxy

Conversation

@UnArbosSix

@UnArbosSix UnArbosSix commented Aug 31, 2026

Copy link
Copy Markdown
Collaborator

Motivation

Operators need to delegate root-basket curation without granting a broader proxy scope. Reusing the deprecated RootWeights variant could unexpectedly reactivate existing delegations, so this change introduces a new proxy type with a fresh wire index.

Changes

  • Add SetRootWeights as proxy type index 18 while leaving deprecated RootWeights at index 12 deny-all.
  • Restrict SetRootWeights to SubtensorModule::set_root_weights.
  • Preserve the existing broad proxy behavior by moving set_root_weights into a dedicated call group included by the same broad filters.
  • Expose the new type through runtime filter metadata and the Python SDK.
  • Update proxy guides, transaction reference pages, and generated intent catalog data.
  • Add tests for the stable SCALE index and exact allowed-call set.

Behavioral and upgrade impact

This is a runtime-facing proxy enum and filter change and therefore takes effect with a runtime upgrade. It requires no storage migration. Existing RootWeights proxies remain deprecated and deny all calls; users must explicitly create or update a proxy using SetRootWeights.

Validation

  • Added unit assertions for wire indices and the SetRootWeights allowlist.
  • git diff --check passes.
  • Rust formatting could not be executed in the review environment because rustup attempted to write to a read-only locked environment.
  • Python Ruff and generated-reference checks could not be executed because the existing environment does not provide uv.

@vercel

vercel Bot commented Aug 31, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
subtensor Ready Ready Preview Aug 31, 2026 3:44pm

Request Review

@UnArbosSix UnArbosSix added the skip-cargo-audit This PR fails cargo audit but needs to be merged anyway label Aug 31, 2026
@github-actions

github-actions Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

🛡️ AI Review — Skeptic (security review)

VERDICT: SAFE

VERY HIGH scrutiny (account under 90 days with 0 public repos), tempered by repository write access, substantive merged history, matching commit authorship, and no Gittensor association; add-set-root-weights-proxy → main.

The change adds a fresh, stable wire index and restricts the new proxy type to set_root_weights. Existing broad proxy permissions remain equivalent, and the trusted AI-review boundary is unchanged.

Findings

No findings.

Conclusion

No malicious behavior or security vulnerability was found in the static diff review.


🔍 AI Review — Auditor (domain review)

VERDICT: 👍

UNKNOWN Gittensor association; account is under 90 days old, but repository write access and substantial merged contribution history support correctness-focused scrutiny.

PR body was empty/trivial; the Auditor has auto-filled it. Please review.

The new proxy receives fresh SCALE index 18, preserves the deprecated index 12 as deny-all, and grants only set_root_weights. Tests cover its wire index and exact allowlist.

Duplicate work: This PR is the better candidate. Recommend closing #3129. Unlike #3129, it avoids silently reactivating existing RootWeights delegations and updates the Python SDK and user documentation.

git diff --check passed. Rust formatting could not run because the locked rustup environment was read-only; Python Ruff and generated-doc checks were unavailable because uv is not installed. No build or runtime test was needed for confirmation.

Findings

No findings.

Conclusion

The implementation safely introduces the narrowly scoped proxy without changing legacy proxy authority, and its tests and documentation are appropriately updated.

@github-actions

Copy link
Copy Markdown
Contributor

🔄 AI review updated — Skeptic: SAFE Auditor: 👍

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.

1 participant