Skip to content

Conversation

@ibraheem-abe
Copy link
Contributor

@ibraheem-abe ibraheem-abe commented Nov 26, 2025

Root stake claim update for netuids

image

Updated commands

1. btcli stake claim

Important

Walks through the steps of selecting > Swap vs Keep
Prompts which subnets to Swap or Keep

image

2. btcli stake claim keep --netuids 1-20, 40-128

Important

Allows to directly set netuids to keep
Using btcli stake claim keep will set keep for all subnets.

image

3. btcli stake claim swap --netuids 1-20, 40-128

Important

Allows to directly set netuids to swap
Using btcli stake claim swap will set swap for all subnets.

image

Enhancements to existing commands

4. btcli subnet metagraph --netuid 0

Important

Now displays a breakdown of validator's root claim settings. Eg: Keep (5) -> Validator is keeping alpha for 5 subnets

image

5. btcli subnet metagraph --netuid 14

Important

Displays current claim type for validators in the subnet
Only neurons who have stake on root will have their claim type

image

@ibraheem-abe ibraheem-abe added enhancement New feature or request Do not merge labels Nov 26, 2025
@ibraheem-abe ibraheem-abe requested a review from a team November 26, 2025 00:43
basfroman
basfroman previously approved these changes Nov 26, 2025
Comment on lines +1054 to +1074
def parse_subnet_range(input_str: str, total_subnets: int) -> list[int]:
"""
Parse subnet range input like "1-24, 30-40, 5".
Args:
input_str: Comma-separated list of subnets and ranges
Examples: "1-5", "1,2,3", "1-5, 10, 20-25"
total_subnets: Total number of subnets available
Returns:
Sorted list of unique subnet IDs
Raises:
ValueError: If input format is invalid
Examples:
>>> parse_subnet_range("1-5, 10")
[1, 2, 3, 4, 5, 10]
>>> parse_subnet_range("5, 3, 1")
[1, 3, 5]
"""
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice logic

@ibraheem-abe ibraheem-abe merged commit 06cc944 into staging Dec 4, 2025
68 checks passed
@ibraheem-abe ibraheem-abe deleted the feat/root-claim-update branch December 4, 2025 00:20
@ibraheem-abe ibraheem-abe mentioned this pull request Dec 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Do not merge enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants