affaan-m/ECC · error

Live node qualification requires --live-sixtytwo exactly onc

Error message

Live node qualification requires --live-sixtytwo exactly once before any process is started.

What it means

The --live-sixtytwo flag must appear exactly once on the command line for live node qualification. The validator counts occurrences and rejects both zero (forgot to opt in) and more than one (ambiguous/duplicated opt-in), consistent with the other exactly-once requirements.

Source

Thrown at scripts/ito.js:113

    .filter((index) => index >= 0);
  if (indexes.length !== 1) {
    throw new Error(`${option} is required exactly once for live node qualification.`);
  }
  const value = args[indexes[0] + 1];
  if (!value?.trim() || value.startsWith("--")) {
    throw new Error(`${option} requires a non-empty value for live node qualification.`);
  }
  return value;
}

function validateNodeQualificationArgs(args, environment) {
  if (environment.ITO_ENABLE_SIXTYTWO_LIVE !== "1") {
    throw new Error(
      "Live node qualification requires ITO_ENABLE_SIXTYTWO_LIVE=1 before any process is started."
    );
  }
  if (args.filter((value) => value === "--live-sixtytwo").length !== 1) {
    throw new Error(
      "Live node qualification requires --live-sixtytwo exactly once before any process is started."
    );
  }
  requiredOptionValue(args, "--cluster");
  const nodes = requiredOptionValue(args, "--nodes");
  if (!nodes.split(",").every((node) => node.trim().length > 0)) {
    throw new Error("--nodes must explicitly list one or more non-empty nodes.");
  }
  const configDirectory = requiredOptionValue(args, "--config-dir");
  if (!path.isAbsolute(configDirectory)) {
    throw new Error("--config-dir must be an existing absolute directory.");
  }
  try {
    const resolved = fs.realpathSync.native(configDirectory);
    if (
      !fs.statSync(resolved).isDirectory()
      || !fs.statSync(path.join(resolved, "sixtytwo.yaml")).isFile()
    ) {

View on GitHub (pinned to 01e15490f0)

Solutions

  1. Include --live-sixtytwo exactly once in the command
  2. Remove the duplicate from either the wrapper or the user override
  3. Use --help to confirm the canonical live-qualification command shape

Example fix

// before
--live-sixtytwo --live-sixtytwo --cluster c1 ...
// after
--live-sixtytwo --cluster c1 ...
Defensive patterns

Strategy: validation

Validate before calling

const liveCount = args.filter(a => a === '--live-sixtytwo').length;
if (liveCount !== 1) {
  throw new Error(`--live-sixtytwo must appear exactly once (found ${liveCount})`);
}

Type guard

function liveSixtytwoExactlyOnce(args) {
  return args.filter(a => a === '--live-sixtytwo').length === 1;
}

Try / catch

try { validateNodeQualificationArgs(args, env); }
catch (err) {
  if (/--live-sixtytwo exactly once/.test(err.message)) {
    console.error(err.message);
    process.exit(2);
  }
  throw err;
}

Prevention

When it happens

Trigger: Omitting --live-sixtytwo while passing the other live options, or passing it twice because a base command and an override both add it.

Common situations: A wrapper that unconditionally adds --live-sixtytwo colliding with a user-supplied copy, or assembling the command from fragments that each include the flag.

Related errors


AI-assisted analysis of affaan-m/ECC@01e15490f0 (2026-08-13). Data as JSON: /api/errors/4c761cea3890c59a. Report an issue: GitHub.