Skip to content

Commit 05617d2

Browse files
committed
fix: update the get children function
1 parent 3caa26d commit 05617d2

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

bittensor_cli/src/commands/stake/children_hotkeys.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -498,10 +498,14 @@ async def _render_table(
498498
)
499499
if not success:
500500
print_error(f"Failed to get children from subtensor: {err_mg}")
501+
502+
# Always render the table, even if there are no children
501503
if children:
502504
netuid_children_tuples = [(netuid, children)]
503-
await _render_table(get_hotkey_pub_ss58(wallet), netuid_children_tuples)
505+
else:
506+
netuid_children_tuples = []
504507

508+
await _render_table(get_hotkey_pub_ss58(wallet), netuid_children_tuples)
505509
return children
506510

507511

0 commit comments

Comments
 (0)