Skip to content

Commit 3e5bf51

Browse files
committed
fix: remove the parent-hotkey which is redundent with wallet hotkey
1 parent c26405f commit 3e5bf51

2 files changed

Lines changed: 1 addition & 14 deletions

File tree

bittensor_cli/cli.py

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6188,12 +6188,6 @@ def stake_set_children(
61886188
network: Optional[list[str]] = Options.network,
61896189
netuid: Optional[int] = Options.netuid_not_req,
61906190
all_netuids: bool = Options.all_netuids,
6191-
parent_hotkey: Optional[str] = typer.Option(
6192-
None,
6193-
"--parent-hotkey",
6194-
help="Parent hotkey SS58 to manage (defaults to the selected wallet hotkey).",
6195-
prompt=False,
6196-
),
61976191
proportions: list[float] = typer.Option(
61986192
[],
61996193
"--proportions",
@@ -6254,10 +6248,6 @@ def stake_set_children(
62546248
validate=WV.WALLET_AND_HOTKEY,
62556249
)
62566250

6257-
if parent_hotkey is not None and not is_valid_ss58_address(parent_hotkey):
6258-
print_error(f"Invalid SS58 address for --parent-hotkey: {parent_hotkey}")
6259-
raise typer.Exit()
6260-
62616251
logger.debug(
62626252
"args:\n"
62636253
f"network: {network}\n"
@@ -6275,7 +6265,6 @@ def stake_set_children(
62756265
netuid=netuid,
62766266
children=children,
62776267
proportions=proportions,
6278-
hotkey=parent_hotkey,
62796268
wait_for_finalization=wait_for_finalization,
62806269
wait_for_inclusion=wait_for_inclusion,
62816270
prompt=prompt,

bittensor_cli/src/commands/stake/children_hotkeys.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -516,7 +516,6 @@ async def set_children(
516516
children: list[str],
517517
proportions: list[float],
518518
netuid: Optional[int] = None,
519-
hotkey: Optional[str] = None,
520519
wait_for_inclusion: bool = True,
521520
wait_for_finalization: bool = True,
522521
prompt: bool = True,
@@ -532,14 +531,13 @@ async def set_children(
532531
children: List of child hotkey SS58 addresses.
533532
proportions: List of stake proportions (floats between 0 and 1).
534533
netuid: Optional specific subnet ID. If None, operates on ALL non-root subnets.
535-
hotkey: Optional parent hotkey SS58 address. If None, uses wallet's hotkey.
536534
wait_for_inclusion: Wait for transaction to be included in a block.
537535
wait_for_finalization: Wait for transaction to be finalized.
538536
prompt: Prompt user for confirmation before submitting transactions.
539537
json_output: Output results as JSON instead of formatted text.
540538
proxy: Optional proxy SS58 address for transaction submission.
541539
"""
542-
parent_hotkey = hotkey if hotkey is not None else get_hotkey_pub_ss58(wallet)
540+
parent_hotkey = get_hotkey_pub_ss58(wallet)
543541

544542
# Validate children SS58 addresses
545543
for child in children:

0 commit comments

Comments
 (0)