Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
# Changelog

## 9.0.1 /2025-02-13

## What's Changed
* Fixes root tempo being 0 by @ibraheem-opentensor in https://github.com/opentensor/btcli/pull/312
* Backmerge main to staging 900 by @ibraheem-opentensor in https://github.com/opentensor/btcli/pull/313
* Fixes fmt err msg by @ibraheem-opentensor in https://github.com/opentensor/btcli/pull/314
* Adds subnet identities set/get by @ibraheem-opentensor in https://github.com/opentensor/btcli/pull/316
* Fix return type annotation for `alpha_to_tao_with_slippage` by @thewhaleking in https://github.com/opentensor/btcli/pull/311
* Updates live view of btcli stake list

**Full Changelog**: https://github.com/opentensor/btcli/compare/v9.0.0...v9.0.1

## 9.0.0 /2025-02-13

## What's Changed
Expand Down
2 changes: 1 addition & 1 deletion bittensor_cli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@
from .cli import CLIManager


__version__ = "9.0.0"
__version__ = "9.0.1"

__all__ = ["CLIManager", "__version__"]
4 changes: 2 additions & 2 deletions bittensor_cli/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class GitError(Exception):
pass


__version__ = "9.0.0"
__version__ = "9.0.1"


_core_version = re.match(r"^\d+\.\d+\.\d+", __version__).group(0)
Expand Down Expand Up @@ -656,7 +656,7 @@ def __init__(self):
self.config_app.command("set")(self.set_config)
self.config_app.command("get")(self.get_config)
self.config_app.command("clear")(self.del_config)
self.config_app.command("metagraph", hidden=True)(self.metagraph_config)
# self.config_app.command("metagraph", hidden=True)(self.metagraph_config)

# wallet commands
self.wallet_app.command(
Expand Down
2 changes: 1 addition & 1 deletion bittensor_cli/src/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Constants:
subvortex_entrypoint = "ws://subvortex.info:9944"
local_entrypoint = "ws://127.0.0.1:9944"
rao_entrypoint = "wss://rao.chain.opentensor.ai:443"
dev_entrypoint = "wss://dev.chain.opentensor.ai:443 "
dev_entrypoint = "wss://dev.chain.opentensor.ai:443"
local_entrypoint = "ws://127.0.0.1:9944"
latent_lite_entrypoint = "wss://lite.sub.latent.to:443"
network_map = {
Expand Down
18 changes: 5 additions & 13 deletions bittensor_cli/src/commands/stake/list.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ async def get_stake_data(block_hash: str = None):
coldkey_ss58=coldkey_address, block_hash=block_hash
),
subtensor.get_delegate_identities(block_hash=block_hash),
subtensor.all_subnets(),
subtensor.all_subnets(block_hash=block_hash),
)
# sub_stakes = substakes[coldkey_address]
dynamic_info = {info.netuid: info for info in _dynamic_info}
Expand Down Expand Up @@ -327,7 +327,7 @@ def format_cell(
alpha_value = Balance.from_rao(int(substake.stake.rao)).set_unit(netuid)
tao_value = pool.alpha_to_tao(alpha_value)
total_tao_value += tao_value
swapped_tao_value, slippage = pool.alpha_to_tao_with_slippage(
swapped_tao_value, slippage, slippage_pct = pool.alpha_to_tao_with_slippage(
substake.stake
)
total_swapped_tao_value += swapped_tao_value
Expand Down Expand Up @@ -385,15 +385,6 @@ def format_cell(
millify=True if not verbose else False,
)

if pool.is_dynamic:
slippage_pct = (
100 * float(slippage) / float(slippage + swapped_tao_value)
if slippage + swapped_tao_value != 0
else 0
)
else:
slippage_pct = 0

if netuid != 0:
swap_cell = (
format_cell(
Expand Down Expand Up @@ -463,11 +454,12 @@ def format_cell(
return table, current_data

# Main execution
block_hash = await subtensor.substrate.get_chain_head()
(
sub_stakes,
registered_delegate_info,
dynamic_info,
) = await get_stake_data()
) = await get_stake_data(block_hash)
balance = await subtensor.get_balance(coldkey_address)

# Iterate over substakes and aggregate them by hotkey.
Expand Down Expand Up @@ -556,7 +548,7 @@ def format_cell(
table, current_data = create_live_table(
selected_stakes,
registered_delegate_info,
dynamic_info,
dynamic_info_,
hotkey_name,
previous_data,
)
Expand Down
2 changes: 1 addition & 1 deletion bittensor_cli/src/commands/subnets/subnets.py
Original file line number Diff line number Diff line change
Expand Up @@ -890,7 +890,7 @@ async def show_root():
for netuid_ in range(len(all_subnets)):
subnet = all_subnets[netuid_]
emission_on_subnet = (
root_state.emission_history[netuid_][idx] / subnet.tempo
root_state.emission_history[netuid_][idx] / (subnet.tempo or 1)
)
total_emission_per_block += subnet.alpha_to_tao(
Balance.from_rao(emission_on_subnet)
Expand Down
Loading