From the review on PR #1: #1 (comment)
The six commands are pinned by two repositories and called by name from a shared workflow and from a repo-local skill. These are cheap to change now and breaking to change later.
--exclude uses nargs="*" and swallows the site positional. check-anchors --exclude 'print_page/*' build checked ./site, never touching build. docs.halos.fi is the consumer that needs this flag, and the shared workflow will interpolate the site directory from an input where ordering is not obvious. Make it action="append", one pattern per occurrence — the ambiguity disappears and argument order stops mattering.
--check prints its failure block to stdout. The README documents translation-status --comment > body.md; adding --check for the exit status writes the gate diagnostic into the file after the <!-- translation-status --> marker, as an unbounded indented list that renders as a run-on paragraph. Send render_failure to stderr — it is a diagnostic for the job log, not part of the artifact a format flag promised. test_comment_and_check_compose currently asserts the contamination as intended and needs updating with it.
--diff and --only-pages are silently inert with the default text format. Accepted, ignored, exit 0 — and --diff still pays for the git cat-file and git diff work before throwing it away. Either honour them in render_text or reject the combination.
--docs exists on check-glossary and nowhere else; the other five hard-code docs/. Adding it to the rest later is additive, removing it later is not. Pointing --docs at another tree also takes the locale from the wrong repository, since mkdocs.yml still resolves from the working directory.
- No
--version on any command, and nothing ties the git tag to project.version. A release tagged against an unbumped pyproject ships a package that reports the wrong version, and no log can answer "which version ran" when two consumers sit on different pins.
check-typography --help advertises [] as a valid locale. choices=[*sorted(QUOTES), []] works around argparse validating an empty default, and the sentinel leaks into the usage line and the error text. Drop choices and validate in main with parser.error.
From the review on PR #1: #1 (comment)
The six commands are pinned by two repositories and called by name from a shared workflow and from a repo-local skill. These are cheap to change now and breaking to change later.
--excludeusesnargs="*"and swallows thesitepositional.check-anchors --exclude 'print_page/*' buildchecked./site, never touchingbuild.docs.halos.fiis the consumer that needs this flag, and the shared workflow will interpolate the site directory from an input where ordering is not obvious. Make itaction="append", one pattern per occurrence — the ambiguity disappears and argument order stops mattering.--checkprints its failure block to stdout. The README documentstranslation-status --comment > body.md; adding--checkfor the exit status writes the gate diagnostic into the file after the<!-- translation-status -->marker, as an unbounded indented list that renders as a run-on paragraph. Sendrender_failureto stderr — it is a diagnostic for the job log, not part of the artifact a format flag promised.test_comment_and_check_composecurrently asserts the contamination as intended and needs updating with it.--diffand--only-pagesare silently inert with the default text format. Accepted, ignored, exit 0 — and--diffstill pays for thegit cat-fileandgit diffwork before throwing it away. Either honour them inrender_textor reject the combination.--docsexists oncheck-glossaryand nowhere else; the other five hard-codedocs/. Adding it to the rest later is additive, removing it later is not. Pointing--docsat another tree also takes the locale from the wrong repository, sincemkdocs.ymlstill resolves from the working directory.--versionon any command, and nothing ties the git tag toproject.version. A release tagged against an unbumpedpyprojectships a package that reports the wrong version, and no log can answer "which version ran" when two consumers sit on different pins.check-typography --helpadvertises[]as a valid locale.choices=[*sorted(QUOTES), []]works around argparse validating an empty default, and the sentinel leaks into the usage line and the error text. Dropchoicesand validate inmainwithparser.error.