Skip to content

fix: remove unused --hotkey option and split inspect into two tables#841

Open
Nicknamess96 wants to merge 1 commit intoopentensor:stagingfrom
Nicknamess96:fix/inspect-hotkey-support
Open

fix: remove unused --hotkey option and split inspect into two tables#841
Nicknamess96 wants to merge 1 commit intoopentensor:stagingfrom
Nicknamess96:fix/inspect-hotkey-support

Conversation

@Nicknamess96
Copy link

Summary

Address the remaining work from #233 by removing the regressed --hotkey parameter from the wallet inspect command and splitting the single combined table into two separate, focused tables as suggested by @thewhaleking.

PR #770 previously removed the --hotkey option, but subsequent merges re-introduced the parameter and reverted the help text. This PR re-applies those fixes and additionally splits the inspect output into:

  1. Coldkey Overview table: Coldkey, Balance, Delegate, Stake, Emission
  2. Hotkey Details table: Coldkey, Netuid, Hotkey, Stake, Emission

Changes

  • Removed wallet_hotkey parameter from wallet_inspect CLI handler
  • Updated help text to describe the two-table output format
  • Passed None for hotkey in wallet_ask call (hotkey is not used by inspect)
  • Refactored single 9-column table into two 5-column tables
  • Extracted helper functions: _build_coldkey_table, _build_hotkey_table, _make_delegate_rows, _make_neuron_rows, _resolve_delegate_name, _calculate_daily_return, _format_hotkey_label, _populate_coldkey_table, _populate_hotkey_table
  • Removed unused itertools import
  • Added 17 unit tests covering all new helper functions

Fixes #233

Testing

  • Full unit test suite passes (pytest tests/unit_tests/ -- 81 passed)
  • Formatted with ruff format . (v0.11.5)
  • Linted with ruff check . on changed files

Remove the regressed --hotkey parameter from wallet inspect command
and split the single 9-column table into two focused tables:
a Coldkey Overview table and a Hotkey Details table.

- Remove wallet_hotkey parameter from wallet_inspect signature
- Update help text to reflect coldkey-only wallet display
- Refactor inspect output into separate coldkey and hotkey tables
- Extract helper functions for delegate/neuron row generation
- Add unit tests for all new helper functions
- Remove unused itertools import

Fixes opentensor#233
@thewhaleking thewhaleking requested a review from a team February 26, 2026 07:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant