{"record":{"id":"1fc68ae9d9dbb592","repo":"affaan-m/ECC","slug":"it-compute-has-no-paper-or-dry-run-success-mode","errorCode":null,"errorMessage":"Itô compute has no paper or dry-run success mode. No CLI operation was invoked.","messagePattern":"Itô compute has no paper or dry-run success mode\\. No CLI operation was invoked\\.","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"scripts/ito.js","lineNumber":152,"sourceCode":"  } catch {\n    throw new Error(\n      \"--config-dir must exist and contain a regular sixtytwo.yaml before any process is started.\"\n    );\n  }\n}\n\nfunction parseArgs(argv, environment = process.env) {\n  const args = [...argv];\n  if (\n    args.length === 0\n    || args.includes(\"--help\")\n    || args.includes(\"-h\")\n  ) {\n    return Object.freeze({ help: true, invocationArgs: [] });\n  }\n\n  if (environment.ECC_DRY_RUN === \"1\" || args.includes(\"--dry-run\")) {\n    throw new Error(\n      \"Itô compute has no paper or dry-run success mode. No CLI operation was invoked.\"\n    );\n  }\n\n  const jsonIndexes = args\n    .map((value, index) => (value === \"--json\" ? index : -1))\n    .filter((index) => index >= 0);\n  if (jsonIndexes.length > 1) {\n    throw new Error(\"--json may only be provided once\");\n  }\n  const withoutJson = args.filter((value) => value !== \"--json\");\n  const command = withoutJson.shift();\n  if (!SUPPORTED_COMMANDS.includes(command)) {\n    throw new Error(\n      `Unsupported Itô command \"${command || \"(missing)\"}\"; ECC permits only login, logout, auth, find, status, and evals.`\n    );\n  }\n  if (command === \"auth\" && withoutJson.includes(\"--no-browser\")) {","sourceCodeStart":134,"sourceCodeEnd":170,"githubUrl":"https://github.com/affaan-m/ECC/blob/01e15490f04e29cfefe3896951f43db46994d8ee/scripts/ito.js#L134-L170","documentation":"Thrown by parseArgs at scripts/ito.js:152 when ECC_DRY_RUN=1 is set in the environment OR --dry-run appears anywhere in the argv. The Itô bridge is a credential-bearing financial CLI that forwards to a real Itô client; there is intentionally no paper-trading or no-op success mode. The error exists to prevent a dry-run habit from silently masking the fact that no real operation ran — the operator would believe an RFQ or qualification happened when it did not.","triggerScenarios":"Any of: `ECC_DRY_RUN=1 ecc ito login`; `ecc ito status --dry-run`; `ecc ito find <opts> --dry-run`. The check runs before command parsing, so even `ecc ito --dry-run` (no subcommand) trips it. It also fires before the --json and SUPPORTED_COMMANDS checks at ito.js:157-169.","commonSituations":"A shell that exports ECC_DRY_RUN=1 globally for testing other ECC subcommands, then the operator runs `ecc ito ...` in the same shell expecting real behavior. CI pipelines that set ECC_DRY_RUN for safe invocation of unrelated ECC tooling also trip this when reaching an ito step.","solutions":["Unset the env var for the ito invocation: `env -u ECC_DRY_RUN ecc ito status`.","Remove --dry-run from the arguments; the ito bridge has no dry-run equivalent.","If you genuinely need a non-mutating ito call, use `ecc ito auth` (validation-only) or `ecc ito status` (read-only) without --dry-run.","Audit your shell rc / CI env for a global ECC_DRY_RUN export and scope it tightly."],"exampleFix":"// before\n$ ECC_DRY_RUN=1 ecc ito status\n// after\n$ ecc ito status","handlingStrategy":"validation","validationCode":"function assertNoDryRun(env, argv) {\n  if (env.ECC_DRY_RUN === '1' || argv.includes('--dry-run')) {\n    throw new Error('Refusing to invoke ecc ito under dry-run; unset ECC_DRY_RUN and remove --dry-run.');\n  }\n}\n// in the wrapper that invokes ecc ito\nassertNoDryRun(process.env, process.argv.slice(2));","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never export ECC_DRY_RUN globally; scope it to the specific subcommand that needs it.","Document in your team's runbook that `ecc ito` has no dry-run mode by design.","In CI, explicitly `env -u ECC_DRY_RUN` around ito steps to insulate them from global config."],"tags":["cli","ito","dry-run","environment","intentional-design"],"backgroundTag":null,"analyzedSha":"01e15490f04e29cfefe3896951f43db46994d8ee","analyzedAt":"2026-08-13T00:31:08.655Z","schemaVersion":2},"datasetVersion":"2026-08-13T04:17:16.726Z"}