GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Design: unknown means stop — one strict argument contract for the repo's operator scripts · Issue #3352 · developing-today/code

Design: unknown means stop — one strict argument contract for the repo's operator scripts #3352

New issue
Copy link
New issue
Copy link
Closed
12 / 1212 of 12 issues completed
Closed
Design: unknown means stop — one strict argument contract for the repo's operator scripts#3352
12 / 1212 of 12 issues completed
Copy link
Assignees
dezren39
Labels
effort/lLarge: multi-day or open-ended; expect staged check-insepicMeta-issue grouping multiple items (org Project Type=Epic)kind/designA design proposal (design-architect): multi-step, phased, decision-bearingmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/highImportant and time-sensitivesource/design-architectFiled by the repo design architect jobstatus/donetask/triageQueue packet kind: verify, reproduce, and route this item

Description

@dezren39
dezren39
opened on Nov 1, 2026
Issue body actions

Design (design-architect pass 30, 2026-11-01). Full design doc: files/designs/code-operator-argument-contract.md in the keep-the-four-repos-healthy goal workspace. Audited at origin/main 5de8ee19. No user/review: every origin carries explicit acceptance with a verified laptop probe, and the judgment calls below are the architect's recorded decisions.

Summary

The repo's operator scripts parse their command lines by membership test — args.includes("--dry-run"), argv.indexOf("--store") — and are silent about everything else. Ten filings in three days are that silence, in two costumes plus a sibling:

  • Unknown argument silently ignored → the mutating operation runs. pkarr-worker(deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu or --deploy-version=<id> performs a real deploy of HEAD #3264 (pkarr-worker deploy: --dry-rnu deploys for real; --deploy-version=<id> falls through to deploying HEAD), github-backup(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real deploy (upload + secret reset) #3287 (github-backup worker deploy, written after pkarr-worker(deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu or --deploy-version=<id> performs a real deploy of HEAD #3264 was filed), id-mail(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu enters the real deploy sequence and force-deletes the retired 'id-mail' Worker #3281 (id-mail worker deploy: a typo'd preview force-deletes the retired Worker, then deploys), opencode-claimant(install): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real install, and a typo'd --stor writes the real OpenChamber store #3278 (opencode-claimant install: typo'd --dry-rnu installs for real; typo'd --stor silently re-aims at the real OpenChamber store), proxy-supervise: unrecognized arguments are silently ignored — a typo'd --dry-rnu starts/rolls real proxies, and a typo'd --statuz reconciles instead of reporting status #3296 (proxy-supervise: --dry-rnu starts real proxies; --statuz reconciles instead of reporting status), sync-models: unrecognized arguments are silently ignored — a typo'd --dry-rnu rewrites the live OpenCode config in place (and reloads opencode) #3297 (sync-models: a typo'd preview rewrites the live OpenCode config and reloads opencode).
  • A value option present but valueless is silently replaced / consumed / crashed on. aggregator(charges-producer): a trailing or flag-like --start/--end/--out value is silently replaced by the defaults — the producer overwrites the live candidates file for the wrong period and exits 0 #3333 (charges producer: trailing --out overwrites the live candidates file via the ?? default), aggregator(backfill): trailing --dir crashes with a raw TypeError, and a flag-like value (--dir --print) silently writes the rebuilt history into a directory named '--print' #3330 (snapshot backfill: trailing --dir raw TypeError; --dir --print writes into a directory named --print), aggregator(snapshots): append-usage-snapshots --by with no value silently discards every derived record — exit 0, 'no records derived' #3295 (snapshot append: trailing --by silently discards the run's records, exit 0), mcpx(docs-history): a value-taking flag as the last argument panics — stamp/check arg loops index rest[i] after i++ with no bounds check #3312 (mcpx docs-history, Go: trailing value flag panics instead of printing usage).
  • Sibling: pkarr-worker(deploy): --dry-run is ignored on the --deploy-version path — a rollback preview creates a real 100% deployment #3252 — the recognized --dry-run is dropped on pkarr deploy's --deploy-version branch, so a rollback preview creates a real 100% deployment.

The strict behaviour already exists in-tree (lib/bws-to-sops.sh:53 dies on unknown argument; scripts/stage-docs.sh:45; compact-usage-snapshots.ts:28-31 exits 2 naming a bad value). No operator script uses a strict platform parser (zero parseArgs hits). Sibling contracts: #2835 governs env numbers, #3005 measurement strings, dezren39/darwin-nix#1145 another repo's scripts — this repo's argv has no stated contract.

The contract (recorded decisions)

Every argument is accounted for before anything happens. A script declares its whole command line and parses strictly; anything unaccounted for is a usage error naming the offending argument, exit non-zero (2 where no usage code is established), before any subprocess / network / file write / lock / deploy step.

  1. Unknown means stop — unknown flag, stray positional, and typo'd flag are the same event.
  2. --opt=value either works identically to --opt value or is refused under (1) — never a silent fall-through to a different operation (per-tool pin in triage, stated in usage text).
  3. Present-but-valueless is not absent — trailing, flag-valued, or (where non-empty is required) empty values are usage errors naming the option; defaults apply only when the option was not given.
  4. A parsed safety flag (--dry-run, --status) is honoured on every path; tests cover the flag × path matrix.
  5. Per-tool strict parsing (tools deploy independently, three languages, no shared imports); the contract and one probe matrix are shared: unknown flag → zero stubbed side-effect calls; typo'd safety flag → same; value-option edge forms → pinned behaviour; previously valid invocations unchanged.

Phases (adopted origins — no parallel issues)

  • Phase 1 = pkarr-worker(deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu or --deploy-version=<id> performs a real deploy of HEAD #3264 + pkarr-worker(deploy): --dry-run is ignored on the --deploy-version path — a rollback preview creates a real 100% deployment #3252, github-backup(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real deploy (upload + secret reset) #3287, id-mail(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu enters the real deploy sequence and force-deletes the retired 'id-mail' Worker #3281, opencode-claimant(install): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real install, and a typo'd --stor writes the real OpenChamber store #3278, proxy-supervise: unrecognized arguments are silently ignored — a typo'd --dry-rnu starts/rolls real proxies, and a typo'd --statuz reconciles instead of reporting status #3296, sync-models: unrecognized arguments are silently ignored — a typo'd --dry-rnu rewrites the live OpenCode config in place (and reloads opencode) #3297 (unknown means stop on the side-effecting tools; lands first).
  • Phase 2 = aggregator(charges-producer): a trailing or flag-like --start/--end/--out value is silently replaced by the defaults — the producer overwrites the live candidates file for the wrong period and exits 0 #3333, aggregator(backfill): trailing --dir crashes with a raw TypeError, and a flag-like value (--dir --print) silently writes the rebuilt history into a directory named '--print' #3330, aggregator(snapshots): append-usage-snapshots --by with no value silently discards every derived record — exit 0, 'no records derived' #3295, mcpx(docs-history): a value-taking flag as the last argument panics — stamp/check arg loops index rest[i] after i++ with no bounds check #3312 (present-but-valueless; independent of Phase 1).
  • Phase 3 = closing inventory audit + contract statement (filed as a sub-issue, gated on Phases 1–2): every remaining hand-rolled argv parser in bin/, pm-stack/*/scripts/, deploy/install scripts and the Go tools, dispositioned covered / strict / deliberately lenient with reason (interactive REPL id(repl): find/search/show/peek parsers silently swallow unknown and mistyped flags — a typo'd flag vanishes and its value becomes a query #2274 named deliberately-local; env-value pkarr-worker(retention): RETENTION_SECONDS is parsed with a bare Number() and no guard — '0'/'7d'/' ' schedule the deletion alarm at/before now (or NaN), so stored packets vanish right after a 204, and '1e9' never expires #3261 dispositioned against Design: env numbers are arguments — one strict parse for boot-time configuration #2835/Phase 3 of #2835 — closing inventory audit for the env-number contract + contract docs #2837, not adopted).

Open questions stay in the design doc (repeated value options; short-flag style; a mechanical net; leading-dash values).

Displacement note: this pass's standing candidate was the pkgs/id plain-output rendering family (#2839/#3111/#3089, pass 29). It is displaced by this cluster per pass 29's own watch condition (unknown-args "revisit at a third tool" — now six, plus four) and remains the standing candidate for pass 31.

Acceptance criteria

  • Every operator script in the audit scope either rejects unknown arguments with a non-zero exit and a named error, or is explicitly dispositioned as deliberately lenient with its reason recorded (per the design doc's contract statement).
  • Phases 1-3 (the origin issues named in the design) are filed as linked implementation issues and land or are dispositioned; the closing argv-parser inventory (Phase 3, Phase 3 (audit) of #3352 — closing argv-parser inventory + argument contract statement #3353) finds no un-dispositioned hand-rolled parser in scope.
  • A typo'd flag on a mutating script (e.g. --dry-rnu on a deploy script) provably performs no mutation — verified by probe on at least one script per family.

Sub-issues

Collapse Sub-issuesSub-issues

12 of 1212 of 12 Issues completed
Loading 12 sub-issues

Activity

Next
  1. dezren39
    added
    status/needs-triageNot yet triaged; needs a first look
    epicMeta-issue grouping multiple items (org Project Type=Epic)
    kind/designA design proposal (design-architect): multi-step, phased, decision-bearing
    source/design-architectFiled by the repo design architect job
    on Nov 1, 2026
  2. dezren39
    added sub-issues on Nov 1, 2026
    • pkarr-worker(deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu or --deploy-version=<id> performs a real deploy of HEAD #3264
    • pkarr-worker(deploy): --dry-run is ignored on the --deploy-version path — a rollback preview creates a real 100% deployment #3252
    • opencode-claimant(install): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real install, and a typo'd --stor writes the real OpenChamber store #3278
    • id-mail(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu enters the real deploy sequence and force-deletes the retired 'id-mail' Worker #3281
    • github-backup(worker deploy): unrecognized arguments are silently ignored — a typo'd --dry-rnu performs a real deploy (upload + secret reset) #3287
    • proxy-supervise: unrecognized arguments are silently ignored — a typo'd --dry-rnu starts/rolls real proxies, and a typo'd --statuz reconciles instead of reporting status #3296
    • sync-models: unrecognized arguments are silently ignored — a typo'd --dry-rnu rewrites the live OpenCode config in place (and reloads opencode) #3297
    • aggregator(charges-producer): a trailing or flag-like --start/--end/--out value is silently replaced by the defaults — the producer overwrites the live candidates file for the wrong period and exits 0 #3333
    • aggregator(backfill): trailing --dir crashes with a raw TypeError, and a flag-like value (--dir --print) silently writes the rebuilt history into a directory named '--print' #3330
    • aggregator(snapshots): append-usage-snapshots --by with no value silently discards every derived record — exit 0, 'no records derived' #3295
    • mcpx(docs-history): a value-taking flag as the last argument panics — stamp/check arg loops index rest[i] after i++ with no bounds check #3312
  3. 118 remaining items

  4. dezren39
    added 14 commits that reference this issue on Nov 17, 2026

    fix(fleet): placement-record rejects stray arguments (#3352)

    e288039

    atlas(classification): unclassified-remainder sweep and schema-change…

    2856691

    fix(route-audit): reject undeclared single-dash flags in pool-orderin…

    92f73fd

    feat(id): scripted five-minute path with elapsed time (#12595)

    d4f6925

    fix(fleet): restore-row-count-diff.sh missing option value is a usage…

    f3e9d65

    impl(fleet-hosted): thin TS CLI — session carriage, create/query/inta…

    ff4bde1

    feat(fleet): gh sync verbs for scripted flows (#10973)

    d142839

    feat(quota-plane): S7 weekly forecast-accuracy review job (#12701)

    47728f4

    Add five-copy freshness readout for #8584 backups

    fcdc99f

    feat(fleet-hosted): recorded Metadata backfill runs + body-vs-DB dive…

    2fefe73

    Measure #9573 free context limits: bounded probe harness with 119-lea…

    388ce54

    tip-hygiene: the #3205 tip census harness (check_tip.py)

    c3a5697

    feat(github-backup): --root adapter for plain_mirror_all (#15000 slice)

    53b4090

    feat(auto-update): U1 slice 2 — daily drift census schedule, registry…

    a1640a5
  5. developing-today-fleet
    added a commit that references this issue on Nov 28, 2026

    CF-5e #15561 slice 2: push registry Turso -> D1 copy + hash-verify to…

    51fd6a8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @dezren39
    dezren39

Labels

effort/lLarge: multi-day or open-ended; expect staged check-insepicMeta-issue grouping multiple items (org Project Type=Epic)kind/designA design proposal (design-architect): multi-step, phased, decision-bearingmeta/enrichedIntake review done: acceptance criteria, links, and normalized labels addedpriority/highImportant and time-sensitivesource/design-architectFiled by the repo design architect jobstatus/donetask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.