Skip to content
Merged
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
13 changes: 8 additions & 5 deletions bittensor_cli/src/bittensor/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,11 +238,14 @@ def get_hotkey_wallets_for_wallet(
def get_coldkey_wallets_for_path(path: str) -> list[Wallet]:
"""Gets all wallets with coldkeys from a given path"""
wallet_path = Path(path).expanduser()
wallets = [
Wallet(name=directory.name, path=path)
for directory in wallet_path.iterdir()
if directory.is_dir()
]
try:
wallets = [
Wallet(name=directory.name, path=path)
for directory in wallet_path.iterdir()
if directory.is_dir()
]
except FileNotFoundError:
wallets = []
return wallets


Expand Down