mirror of
https://github.com/sigp/lighthouse.git
synced 2026-06-30 03:14:25 +00:00
Remove --disable-partial-columns in favour of bool argument to --enable... (#9478)
Similar to https://github.com/sigp/lighthouse/pull/9476, partial columns is a feature expected to become the default soon, so instead of introducing a CLI option that will be removed again soon, consolidate into `--enable-partial-columns` which now takes a boolean argument. Co-Authored-By: Daniel Knopik <daniel@dknopik.de>
This commit is contained in:
@@ -684,21 +684,13 @@ pub fn cli_app() -> Command {
|
||||
.arg(
|
||||
Arg::new("enable-partial-columns")
|
||||
.long("enable-partial-columns")
|
||||
.value_name("BOOLEAN")
|
||||
.help("Enable partial messages for data columns. This can reduce the amount of \
|
||||
data sent over the network. Enabled by default on Hoodi and Sepolia; use \
|
||||
--disable-partial-columns to opt out.")
|
||||
.action(ArgAction::SetTrue)
|
||||
.help_heading(FLAG_HEADER)
|
||||
.display_order(0)
|
||||
)
|
||||
.arg(
|
||||
Arg::new("disable-partial-columns")
|
||||
.long("disable-partial-columns")
|
||||
.help("Disable partial messages for data columns. Use this on Hoodi or Sepolia \
|
||||
to opt out of the default-enabled behavior.")
|
||||
.action(ArgAction::SetTrue)
|
||||
.conflicts_with("enable-partial-columns")
|
||||
.help_heading(FLAG_HEADER)
|
||||
data sent over the network. Enabled by default on Hoodi and Sepolia; set to \
|
||||
\"false\" to opt out.")
|
||||
.action(ArgAction::Set)
|
||||
.num_args(0..=1)
|
||||
.default_missing_value("true")
|
||||
.display_order(0)
|
||||
)
|
||||
/*
|
||||
|
||||
@@ -112,10 +112,8 @@ pub fn get_config<E: EthSpec>(
|
||||
.config_name
|
||||
.as_ref()
|
||||
.is_some_and(|name| matches!(name.as_str(), "hoodi" | "sepolia"));
|
||||
let user_disable_partial_columns = parse_flag(cli_args, "disable-partial-columns");
|
||||
let user_enable_partial_columns = parse_flag(cli_args, "enable-partial-columns");
|
||||
let enable_partial_columns = !user_disable_partial_columns
|
||||
&& (user_enable_partial_columns || default_partial_columns_enabled);
|
||||
let enable_partial_columns = clap_utils::parse_optional(cli_args, "enable-partial-columns")?
|
||||
.unwrap_or(default_partial_columns_enabled);
|
||||
|
||||
if enable_partial_columns {
|
||||
// Partial messages assume that each subnet maps to exactly one column.
|
||||
|
||||
Reference in New Issue
Block a user