Skip to content

The falsifying gate: priv --help and wads pack go --help byte-identical #25

Description

@thorwhalen

The contracted acceptance gate (opsward + coact) is mis-specified: between them those
two repos exercise roughly 6 of the 20 argh-grammar rows — no groups, no functools.partial,
no __name__ mutation, no **kwargs, no bool = True, no quoted annotations, no
collision-suppression-at-scale. Passing it proves the migration mechanics and almost nothing
about the grammar.

This issue is the gate that can actually falsify build-vs-adopt. It is tracked in cw
because a failure here is a cw defect, not a repo defect.

The two subjects

t/priv — 88 commands (47 from __all__ + 22 + 8 + 11 from three zero-arg factories),
__all__ is 47 strings, exactly one object with no __name__ (a functools.partial), zero
name mismatches, two groups whose names stay verbatim under ARGH
(priv git_ops parse-pth-paths — that string is in priv's own CLAUDE.md and README.md
and is emitted as a user-facing suggestion by priv/git_branch_tool.py).

i/wads pack — go(pkg_dir, *, version=None, publish_docs_to=None, verbose: bool = True, ...) (so wads pack go --verbose turns verbosity OFF, and D2 says it must keep doing so),
and populate_pkg_dir with 34 parameters including **configs, where so many first characters
collide that almost no short flags are generated — cw must reproduce the absence.

The one deliberate grammar break in the entire migration

priv packages-from-all-setup-cfgs does not exist today: _fix_partial_funcs in
priv/__main__.py copies __name__ from the base function, so the live CLI registers
packages-from-all-projects and re-exposes -c/--config-type. After migration the command is
correctly named and --config-type is gone (via cw.HIDE). This is the sole entry in
replay(expect_diff=[...]) for the whole fleet.

Acceptance criteria

  • Goldens recorded from the current argh priv and wads pack console scripts before
    any edit, covering: top-level --help, both group --helps, ≥1 command per group,
    pack go --help, pack populate-pkg-dir --help, and ≥1 usage error each.
  • priv --help byte-identical (normalised for COLUMNS) except the one
    expect_diff entry.
  • priv git_ops <cmd> --help byte-identical, group name verbatim under ARGH.
  • wads pack go --help byte-identical, including --version's help column rendering its
    default (default_in_help=True) and --verbose still being store_false.
  • wads pack populate-pkg-dir --help byte-identical, including the near-total absence of
    short flags.
  • --config-type absent from the priv CLI and the function still receives
    'setup.cfg' — asserted at the call, not just the parser.
  • The UserWarning about the partial's leaked bound kwarg fires, naming the HIDE line.
  • Any failure here is filed as a cw bug with a minimal fixture added to the parity
    corpus, not patched in the repo.

Depends on

  • ACCEPTANCE GATE: migrate t/opsward to cw → thorwhalen/opsward (issue not yet filed)
  • ACCEPTANCE GATE: migrate t/coact to cw → thorwhalen/coact (issue not yet filed)

Research & rationale: the canonical spec and the full fleet audit live in the private research ledger (https://github.com/thorwhalen/priv/discussions/65). Effort: large.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions