diff --git a/README.md b/README.md index 50d680833..d2930db91 100644 --- a/README.md +++ b/README.md @@ -137,7 +137,7 @@ You can use `new-mnemonic --help` to see all arguments. Note that if there are m | Argument | Type | Description | | -------- | -------- | -------- | | `--num_validators` | Non-negative integer | The number of signing keys you want to generate. Note that the child key(s) are generated via the same master key. | -| `--mnemonic_language` | String. Options: `简体中文`, `繁體中文`, `český jazyk`, `English`, `Italiano`, `한국어`, `Português`, `Español`. Default to `English` | The mnemonic language | +| `--mnemonic_language` | String. Options: `简体中文`, `繁體中文`, `český jazyk`, `English`, `Italiano`, `한국어`, `Português`, `Español`. Default to `English` | The language of the mnemonic word list | | `--folder` | String. Pointing to `./validator_keys` by default | The folder path for the keystore(s) and deposit(s) | | `--chain` | String. `mainnet` by default | The chain setting for the signing domain. | | `--eth1_withdrawal_address` | String. Eth1 address in hexadecimal encoded form | If this field is set and valid, the given Eth1 address will be used to create the withdrawal credentials. Otherwise, it will generate withdrawal credentials with the mnemonic-derived withdrawal public key in [ERC-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). | diff --git a/staking_deposit/intl/en/cli/new_mnemonic.json b/staking_deposit/intl/en/cli/new_mnemonic.json index feee3ac2b..9a0d3d899 100644 --- a/staking_deposit/intl/en/cli/new_mnemonic.json +++ b/staking_deposit/intl/en/cli/new_mnemonic.json @@ -5,8 +5,8 @@ }, "arg_mnemonic_language": { "default": "english", - "help": "The language that your mnemonic is in", - "prompt": "Please choose your mnemonic language" + "help": "The language of the mnemonic word list", + "prompt": "Please choose the language of the mnemonic word list" }, "msg_mnemonic_presentation": "This is your mnemonic (seed phrase). Write it down and store it safely. It is the ONLY way to retrieve your deposit.", "msg_press_any_key": "Press any key when you have written down your mnemonic.", diff --git a/tests/test_cli/test_new_mnemonic.py b/tests/test_cli/test_new_mnemonic.py index 602d43504..b4eb24d61 100644 --- a/tests/test_cli/test_new_mnemonic.py +++ b/tests/test_cli/test_new_mnemonic.py @@ -10,7 +10,11 @@ from staking_deposit.cli import new_mnemonic from staking_deposit.deposit import cli from staking_deposit.key_handling.key_derivation.mnemonic import abbreviate_words -from staking_deposit.utils.constants import DEFAULT_VALIDATOR_KEYS_FOLDER_NAME, ETH1_ADDRESS_WITHDRAWAL_PREFIX, BLS_WITHDRAWAL_PREFIX +from staking_deposit.utils.constants import ( + BLS_WITHDRAWAL_PREFIX, + DEFAULT_VALIDATOR_KEYS_FOLDER_NAME, + ETH1_ADDRESS_WITHDRAWAL_PREFIX, +) from staking_deposit.utils.intl import load_text from .helpers import clean_key_folder, get_permissions, get_uuid @@ -164,8 +168,10 @@ async def test_script_bls_withdrawal() -> None: assert len(seed_phrase) > 0 # Check files - deposit_file = [key_file for key_file in key_files if key_file.startswith('deposit_data')][0] validator_keys_folder_path = os.path.join(my_folder_path, DEFAULT_VALIDATOR_KEYS_FOLDER_NAME) + _, _, key_files = next(os.walk(validator_keys_folder_path)) + + deposit_file = [key_file for key_file in key_files if key_file.startswith('deposit_data')][0] with open(validator_keys_folder_path + '/' + deposit_file, 'r') as f: deposits_dict = json.load(f) for deposit in deposits_dict: