Skip to content

Commit

Permalink
Chore: fix prompts (#5)
Browse files Browse the repository at this point in the history
* Fix intl json files

* Exclude 'mainnet' in prompt

* Update README

* Bump version to v2.6.1
  • Loading branch information
syjn99 authored Aug 27, 2024
1 parent f986a9c commit a770916
Show file tree
Hide file tree
Showing 18 changed files with 53 additions and 69 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ You can use `bls-to-execution-change --help` to see all arguments. Note that if
| Argument | Type | Description |
| ------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `--bls_to_execution_changes_folder` | String. Pointing to `./bls_to_execution_changes` by default | The folder path for the `bls_to_execution_change-*` JSON file(s) |
| `--chain` | String. `mainnet` by default | The chain setting for the signing domain. |
| `--chain` | String. `over` by default | The chain setting for the signing domain. |
| `--mnemonic` | String. mnemonic split by space. | The mnemonic you used to create withdrawal credentials. |
| `--mnemonic_password` | Optional string. Empty by default. | The mnemonic password you used in your key generation. Note: It's not the keystore password. |
| `--validator_start_index` | Non-negative integer | The index position for the keys to start generating withdrawal credentials in [ERC-2334 format](https://eips.ethereum.org/EIPS/eip-2334#eth2-specific-parameters). |
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

setup(
name="staking_deposit",
version='2.6.0',
version='2.6.1',
py_modules=["staking_deposit"],
packages=find_packages(exclude=('tests', 'docs')),
python_requires=">=3.8,<3.10",
Expand Down
6 changes: 3 additions & 3 deletions staking_deposit/cli/generate_bls_to_execution_change.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
)
from staking_deposit.settings import (
ALL_CHAINS,
PRATER,
MAINNET,
OVER,
get_chain_setting,
get_devnet_chain_setting,
Expand Down Expand Up @@ -74,8 +74,8 @@ def get_password(text: str) -> str:
param_decls='--chain',
prompt=choice_prompt_func(
lambda: load_text(['arg_chain', 'prompt'], func=FUNC_NAME),
# Since `prater` is alias of `goerli`, do not show `prater` in the prompt message.
list(key for key in ALL_CHAINS.keys() if key != PRATER)
# do not show `mainnet` (ethereum mainnet) in the prompt message.
list(key for key in ALL_CHAINS.keys() if key != MAINNET)
),
)
@load_mnemonic_arguments_decorator
Expand Down
6 changes: 3 additions & 3 deletions staking_deposit/cli/generate_keys.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
from staking_deposit.settings import (
ALL_CHAINS,
OVER,
PRATER,
MAINNET,
get_chain_setting,
)

Expand Down Expand Up @@ -76,8 +76,8 @@ def generate_keys_arguments_decorator(function: Callable[..., Any]) -> Callable[
param_decls='--chain',
prompt=choice_prompt_func(
lambda: load_text(['chain', 'prompt'], func='generate_keys_arguments_decorator'),
# Since `prater` is alias of `goerli`, do not show `prater` in the prompt message.
list(key for key in ALL_CHAINS.keys() if key != PRATER)
# do not show `mainnet` (ethereum mainnet) in the prompt message.
list(key for key in ALL_CHAINS.keys() if key != MAINNET)
),
),
jit_option(
Expand Down
8 changes: 4 additions & 4 deletions staking_deposit/intl/ar/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"prompt": "الرجاء اختيار عدد المدققين الذين ترغب في تشغيلهم"
},
"chain": {
"help": "إصدار Ethereum PoS الذي تستهدفه. استخدم \"mainnet\" إذا كنت تودع ETH",
"prompt": "الرجاء اختيار اسم الشبكة/السلسلة (mainnet أو testnet)"
"help": "إصدار Over PoS الذي تستهدفه. استخدم \"over\" إذا كنت تودع OVER",
"prompt": "الرجاء اختيار اسم الشبكة/السلسلة (over أو testnet)"
},
"keystore_password": {
"help": "كلمة المرور التي ستؤمن متاجر المفاتيح الخاصة بك. وسوف تحتاج إلى إعادة إدخال هذا لفك تشفيرها عند إعداد مدققي Ethereum PoS الخاصي بك. (يوصى بعدم استخدام هذه الوسيطة، وانتظر حتى يطلب منك الـ CLI مساعد الذاكرة الخاص وإلا فإنها ستظهر في سجل الغلاف الخاص بك.)",
"prompt": "كلمة المرور التي سوف تؤمن متاجر المفاتيح الخاصة بك. سوف تحتاج إلى إعادة إدخال هذا لفك تشفيرها عند إعداد مدققي Ethereum PoS الخاصين بك.",
"help": "كلمة المرور التي ستؤمن متاجر المفاتيح الخاصة بك. وسوف تحتاج إلى إعادة إدخال هذا لفك تشفيرها عند إعداد مدققي Over PoS الخاصي بك. (يوصى بعدم استخدام هذه الوسيطة، وانتظر حتى يطلب منك الـ CLI مساعد الذاكرة الخاص وإلا فإنها ستظهر في سجل الغلاف الخاص بك.)",
"prompt": "كلمة المرور التي سوف تؤمن متاجر المفاتيح الخاصة بك. سوف تحتاج إلى إعادة إدخال هذا لفك تشفيرها عند إعداد مدققي Over PoS الخاصين بك.",
"confirm": "كرر للتأكيد",
"mismatch": "خطأ: القيمتان اللتان تم إدخالهما غير متطابقتين. الرجاء الكتابة مرة أخرى."
}
Expand Down
2 changes: 1 addition & 1 deletion staking_deposit/intl/el/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"prompt": "Παρακαλώ επιλέξτε πόσους επαληθευτές θέλετε να εκτελέσετε"
},
"chain": {
"help": "Η έκδοση του Ethereum Proof-of-Stake στην οποία στοχεύετε. Χρησιμοποιήστε το \"mainnet\" αν κάνετε κατάθεση ETH",
"help": "Η έκδοση του Over Proof-of-Stake στην οποία στοχεύετε. Χρησιμοποιήστε το \"over\" αν κάνετε κατάθεση OVER",
"prompt": "Παρακαλώ επιλέξτε το όνομα δικτύου/αλυσίδας (κεντρικό δίκτυο ή δίκτυο δοκιμών)"
},
"keystore_password": {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"generate_bls_to_execution_change": {
"arg_generate_bls_to_execution_change" :{
"help": "Generating the SignedBLSToExecutionChange data to enable withdrawals on Ethereum Beacon Chain."
"help": "Generating the SignedBLSToExecutionChange data to enable withdrawals on Over Beacon Chain."
},
"arg_execution_address": {
"help": "The 20-byte (Eth1) execution address that will be used in withdrawal",
Expand All @@ -23,8 +23,8 @@
"confirm": "Please repeat the index to confirm"
},
"arg_chain": {
"help": "The name of Ethereum PoS chain you are targeting. Use \"mainnet\" if you are depositing ETH",
"prompt": "Please choose the (mainnet or testnet) network/chain name"
"help": "The name of Over PoS chain you are targeting. Use \"over\" if you are depositing OVER",
"prompt": "Please choose the (over or testnet) network/chain name"
},
"arg_fork": {
"help": "The fork name of the fork you want to signing the message with.",
Expand Down
8 changes: 4 additions & 4 deletions staking_deposit/intl/en/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
"help": "The folder path for the keystore(s) and deposit(s). Pointing to `./validator_keys` by default."
},
"chain": {
"help": "The name of Ethereum PoS chain you are targeting. Use \"mainnet\" if you are depositing ETH",
"prompt": "Please choose the (mainnet or testnet) network/chain name"
"help": "The name of Over PoS chain you are targeting. Use \"over\" if you are depositing OVER",
"prompt": "Please choose the (over or testnet) network/chain name"
},
"keystore_password": {
"help": "The password that will secure your keystores. You will need to re-enter this to decrypt them when you setup your Ethereum validators. (It is recommended not to use this argument, and wait for the CLI to ask you for your mnemonic as otherwise it will appear in your shell history.)",
"prompt": "Create a password that secures your validator keystore(s). You will need to re-enter this to decrypt them when you setup your Ethereum validators.",
"help": "The password that will secure your keystores. You will need to re-enter this to decrypt them when you setup your Over validators. (It is recommended not to use this argument, and wait for the CLI to ask you for your mnemonic as otherwise it will appear in your shell history.)",
"prompt": "Create a password that secures your validator keystore(s). You will need to re-enter this to decrypt them when you setup your Over validators.",
"confirm": "Repeat your keystore password for confirmation",
"mismatch": "Error: the two entered values do not match. Please type again."
},
Expand Down
4 changes: 2 additions & 2 deletions staking_deposit/intl/fr/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"prompt": "Veuillez choisir le nombre de validateurs que vous souhaitez exécuter"
},
"chain": {
"help": "Version Ethereum Proof of Stake que vous ciblez. Utilisez \"mainnet\" si vous déposez de l'ETH.",
"prompt": "Veuillez choisir un nom de chaîne/réseau : mainnet (réseau principal) ou testnet (réseau de test)."
"help": "Version Over Proof of Stake que vous ciblez. Utilisez \"over\" si vous déposez de l'OVER.",
"prompt": "Veuillez choisir un nom de chaîne/réseau : over (réseau principal) ou testnet (réseau de test)."
},
"keystore_password": {
"help": "Mot de passe qui sécurisera vos keystores. Vous devrez le saisir de nouveau pour les décrypter quand vous configurerez vos validateurs Proof of Stake. (Il est recommandé de ne pas utiliser cet argument et d'attendre que l'ILC vous demande votre phrase mnémonique, sinon il apparaîtra dans l'historique de votre interpréteur.)",
Expand Down
8 changes: 4 additions & 4 deletions staking_deposit/intl/id/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"prompt": "Silakan pilih berapa banyak validator yang ingin Anda jalankan"
},
"chain": {
"help": "Versi Ethereum PoS yang Anda targetkan. Gunakan \"mainnet\" jika Anda menyetorkan ETH",
"prompt": "Pilih nama jaringan / rantai (mainnet atau testnet)"
"help": "Versi Over PoS yang Anda targetkan. Gunakan \"over\" jika Anda menyetorkan OVER",
"prompt": "Pilih nama jaringan / rantai (over atau testnet)"
},
"keystore_password": {
"help": "Kata sandi yang akan mengamankan keystore Anda. Anda perlu memasukkan ulang ini untuk mendekripsinya ketika Anda mengatur validator Ethereum PoS Anda. (Disarankan untuk tidak menggunakan argumen ini, dan tunggu CLI menanyakan mnemonik Anda supaya tidak akan muncul dalam riwayat shell Anda.)",
"prompt": "Kata sandi yang akan mengamankan keystore Anda. Anda perlu memasukkan ulang ini untuk mendekripsinya ketika Anda mengatur validator Ethereum PoS Anda.",
"help": "Kata sandi yang akan mengamankan keystore Anda. Anda perlu memasukkan ulang ini untuk mendekripsinya ketika Anda mengatur validator Over PoS Anda. (Disarankan untuk tidak menggunakan argumen ini, dan tunggu CLI menanyakan mnemonik Anda supaya tidak akan muncul dalam riwayat shell Anda.)",
"prompt": "Kata sandi yang akan mengamankan keystore Anda. Anda perlu memasukkan ulang ini untuk mendekripsinya ketika Anda mengatur validator Over PoS Anda.",
"confirm": "Ulangi untuk konfirmasi",
"mismatch": "Kesalahan: dua nilai yang dimasukkan tidak cocok. Silakan ketik ulang."
}
Expand Down
4 changes: 2 additions & 2 deletions staking_deposit/intl/it/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
"prompt": "Scegli quanti validatori vuoi eseguire"
},
"chain": {
"help": "La versione desiderata della Ethereum PoS chain. Utilizzare \"mainnet\" se depositano ETH",
"help": "La versione desiderata della Over PoS chain. Utilizzare \"over\" se depositano OVER",
"prompt": "Scegli il nome delle rete/catena (rete principale o di test)"
},
"keystore_password": {
"help": "La password che proteggerà gli archivi chiavi. Dovrà essere inserita per decrittografare le chiavi durante la configurazione dei validatori della Ethereum PoS chain (è consigliabile non utilizzare questo argomento e attendere che il CLI chieda il mnemonico, altrimenti apparirà nella cronologia della shell).",
"help": "La password che proteggerà gli archivi chiavi. Dovrà essere inserita per decrittografare le chiavi durante la configurazione dei validatori della Over PoS chain (è consigliabile non utilizzare questo argomento e attendere che il CLI chieda il mnemonico, altrimenti apparirà nella cronologia della shell).",
"prompt": "La password che proteggerà gli archivi chiavi. Dovrai inserirla nuovamente per decrittografare gli archivi quando configurerai i tuoi validatori.",
"confirm": "Ripeti per conferma",
"mismatch": "Errore: i due valori inseriti non corrispondono. Ripeti l'inserimento."
Expand Down
6 changes: 3 additions & 3 deletions staking_deposit/intl/ja/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"prompt": "実行したいバリデーターの数を選択してください"
},
"chain": {
"help": "ターゲットとしている Ethereum PoS のバージョン。ETH を入金する場合は \"mainnet\" を使用してください。",
"prompt": "(mainnet または testnet) ネットワーク/チェーン名を選択してください"
"help": "ターゲットとしている Over PoS OVER を入金する場合は \"over\" を使用してください。",
"prompt": "(over または testnet) ネットワーク/チェーン名を選択してください"
},
"keystore_password": {
"help": "キーを生成するために使用したニーモニック。 (この引数を使用せずにCLIからニーモニックの入力が求められるのを待つことをお勧めします。そうしないとシェル履歴に表示されます。)",
"prompt": "キーストアを保護するパスワード。Ethereum PoS バリデーターをセットアップする際に復号化するためにこれを再入力する必要があります。",
"prompt": "キーストアを保護するパスワード。Over PoS バリデーターをセットアップする際に復号化するためにこれを再入力する必要があります。",
"confirm": "確認のために繰り返し入力してください。",
"mismatch": "エラー:入力された2つの値が一致しません。もう一度入力してください。"
}
Expand Down
8 changes: 4 additions & 4 deletions staking_deposit/intl/ko/cli/generate_keys.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"prompt": "실행하려는 검증자의 개수를 선택하세요."
},
"chain": {
"help": "타겟팅하려는 Ethereum PoS의 버전입니다. ETH를 예치한다면 \"mainnet\"을 사용하세요.",
"prompt": "(메인넷 또는 테스트넷) 네트워크/체인 이름을 선택하세요."
"help": "타겟팅하려는 Over PoS의 버전입니다. OVER를 예치한다면 \"over\"을 사용하세요.",
"prompt": "(over 또는 testnet) 네트워크/체인 이름을 선택하세요."
},
"keystore_password": {
"help": "키스토어를 안전하게 보호하는 비밀번호입니다. Ethereum PoS 검증자를 셋업할 때 다시 입력하여 복호화해야 합니다. (이 인수를 사용하지 말고 CLI가 니모닉을 요청할 때까지 기다리는 것이 좋습니다. 기다리지 않으면 셸 기록에 표시되기 때문입니다.)",
"prompt": "키스토어를 안전하게 보호하는 비밀번호입니다. Ethereum PoS 검증자를 셋업할 때 다시 입력하여 복호화해야 합니다.",
"help": "키스토어를 안전하게 보호하는 비밀번호입니다. Over PoS 검증자를 셋업할 때 다시 입력하여 복호화해야 합니다. (이 인수를 사용하지 말고 CLI가 니모닉을 요청할 때까지 기다리는 것이 좋습니다. 기다리지 않으면 셸 기록에 표시되기 때문입니다.)",
"prompt": "키스토어를 안전하게 보호하는 비밀번호입니다. Over PoS 검증자를 셋업할 때 다시 입력하여 복호화해야 합니다.",
"confirm": "확인을 위해 동일하게 입력",
"mismatch": "오류: 입력한 두 값이 일치하지 않습니다. 다시 입력하세요."
}
Expand Down
Loading

0 comments on commit a770916

Please sign in to comment.