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
4 changes: 0 additions & 4 deletions bittensor_cli/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -2881,9 +2881,6 @@ def stake_add(
)
raise typer.Exit()

if not stake_all and not amount:
amount = FloatPrompt.ask("Amount to [blue]stake (TAO τ)[/blue]")

if stake_all and not amount:
if not Confirm.ask("Stake all the available TAO tokens?", default=False):
raise typer.Exit()
Expand Down Expand Up @@ -3747,7 +3744,6 @@ def stake_set_children(
[],
"--proportions",
"--prop",
"-p",
help="Enter the stake weight proportions for the child hotkeys (sum should be less than or equal to 1)",
prompt=False,
),
Expand Down
2 changes: 1 addition & 1 deletion bittensor_cli/src/bittensor/extrinsics/registration.py
Original file line number Diff line number Diff line change
Expand Up @@ -693,7 +693,7 @@ async def burned_register_extrinsic(
:return: Flag is `True` if extrinsic was finalized or included in the block. If we did not wait for
finalization/inclusion, the response is `True`.
"""

if not (unlock_status := unlock_key(wallet, print_out=False)).success:
return False, unlock_status.message

Expand Down
1 change: 0 additions & 1 deletion bittensor_cli/src/bittensor/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@

if TYPE_CHECKING:
from bittensor_cli.src.bittensor.chain_data import SubnetHyperparameters
from async_substrate_interface.async_substrate import AsyncSubstrateInterface

console = Console()
err_console = Console(stderr=True)
Expand Down
4 changes: 2 additions & 2 deletions bittensor_cli/src/commands/subnets/subnets.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
if TYPE_CHECKING:
from bittensor_cli.src.bittensor.subtensor_interface import SubtensorInterface

TAO_WEIGHT = 0.018
TAO_WEIGHT = 0.18

# helpers and extrinsics

Expand Down Expand Up @@ -1322,7 +1322,7 @@ async def show_subnet(netuid_: int):
return hotkey
else:
console.print(
f"[red]Invalid UID. Please enter a valid UID from the table above[/red]"
"[red]Invalid UID. Please enter a valid UID from the table above[/red]"
)
except ValueError:
console.print("[red]Please enter a valid number[/red]")
Expand Down
16 changes: 8 additions & 8 deletions bittensor_cli/src/commands/sudo.py
Original file line number Diff line number Diff line change
Expand Up @@ -657,10 +657,10 @@ async def senate_vote(
return False

# Unlock the wallet.
try:
wallet.unlock_hotkey()
wallet.unlock_coldkey()
except KeyFileError:
if (
not unlock_key(wallet, "hot").success
and unlock_key(wallet, "cold").success
):
return False

console.print(f"Fetching proposals in [dark_orange]network: {subtensor.network}")
Expand Down Expand Up @@ -736,10 +736,10 @@ async def _do_set_take() -> bool:
f"Setting take on [{COLOR_PALETTE['GENERAL']['LINKS']}]network: {subtensor.network}"
)

try:
wallet.unlock_hotkey()
wallet.unlock_coldkey()
except KeyFileError:
if (
not unlock_key(wallet, "hot").success
and unlock_key(wallet, "cold").success
):
return False

result_ = await _do_set_take()
Expand Down
2 changes: 1 addition & 1 deletion bittensor_cli/src/commands/wallets.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

import aiohttp
from bittensor_wallet import Wallet, Keypair
from bittensor_wallet.errors import KeyFileError, PasswordError
from bittensor_wallet.errors import KeyFileError
from bittensor_wallet.keyfile import Keyfile
from fuzzywuzzy import fuzz
from rich import box
Expand Down
Loading