Update staking-deposit-cli to ethstaker-deposit-cli (#7518)

This commit is contained in:
chonghe
2025-06-03 12:13:57 +08:00
committed by GitHub
parent ae30480926
commit f67068e1ec
19 changed files with 37 additions and 35 deletions

View File

@@ -19,9 +19,9 @@ use zeroize::Zeroizing;
pub const IGNORE_DUPLICATES_FLAG: &str = "ignore-duplicates";
pub const COUNT_FLAG: &str = "count";
/// When the `ethereum/staking-deposit-cli` tool generates deposit data JSON, it adds a
/// When the `ethstaker-deposit-cli` tool generates deposit data JSON, it adds a
/// `deposit_cli_version` to protect the web-based "Launchpad" tool against a breaking change that
/// was introduced in `ethereum/staking-deposit-cli`. Lighthouse don't really have a version that it
/// was introduced in `ethstaker-deposit-cli`. Lighthouse don't really have a version that it
/// can use here, so we choose a static string that is:
///
/// 1. High enough that it's accepted by Launchpad.
@@ -163,12 +163,12 @@ pub struct CreateSpec {
pub validators: Vec<ValidatorSpecification>,
}
/// The structure generated by the `staking-deposit-cli` which has become a quasi-standard for
/// The structure generated by the `ethstaker-deposit-cli` which has become a quasi-standard for
/// browser-based deposit submission tools (e.g., the Ethereum Launchpad and Lido).
///
/// We assume this code as the canonical definition:
///
/// https://github.com/ethereum/staking-deposit-cli/blob/76ed78224fdfe3daca788d12442b3d1a37978296/staking_deposit/credentials.py#L131-L144
/// https://github.com/eth-educators/ethstaker-deposit-cli/blob/80d536374de838ccae142974ed0e747b46beb030/ethstaker_deposit/credentials.py#L164-L177
#[derive(Debug, PartialEq, Serialize, Deserialize)]
pub struct StandardDepositDataJson {
#[serde(with = "public_key_bytes_without_0x_prefix")]

View File

@@ -43,7 +43,7 @@ pub fn cli_app() -> Command {
contains all the validator keystores and other validator data. This file can then \
be imported to a validator client using the \"import-validators\" command. \
Another, optional JSON file is created which contains a list of validator \
deposits in the same format as the \"ethereum/staking-deposit-cli\" tool.",
deposits in the same format as the \"ethstaker-deposit-cli\" tool.",
)
.arg(
Arg::new(OUTPUT_PATH_FLAG)
@@ -487,7 +487,7 @@ impl ValidatorsAndDeposits {
};
// Create a JSON structure equivalent to the one generated by
// `ethereum/staking-deposit-cli`.
// `ethstaker-deposit-cli`.
let json_deposit = StandardDepositDataJson::new(
&voting_keypair,
withdrawal_credentials.into(),

View File

@@ -55,7 +55,7 @@ pub fn cli_app() -> Command {
.help(
"The path to a keystore JSON file to be \
imported to the validator client. This file is usually created \
using staking-deposit-cli or ethstaker-deposit-cli",
using ethstaker-deposit-cli",
)
.action(ArgAction::Set)
.display_order(0)