You can store your password with the following code:
from bittensor_wallet import Wallet
my_wallet = Wallet()
# the same approach you can use `for hotkey_file` if this is encrypted.
boolean_result = my_wallet.coldkey_file.save_password_to_env("mypassword")
In bittensor-wallet version 2.0.2 method save_password_to_env returns True in successful case and False if something wrong. I gonna replace the return result to encrypted password. Then you can get it like this:
from bittensor_wallet import Wallet
my_wallet = Wallet()
my_encrypted_password = my_wallet.coldkey_file.save_password_to_env("mypassword")
You can store your password with the following code:
In
bittensor-wallet
version 2.0.2 methodsave_password_to_env
returnsTrue
in successful case andFalse
if something wrong. I gonna replace the return result to encrypted password. Then you can get it like this: