Skip to content

test: strip jq CRs and probe for a working strace in Windows Git Bash hook suites - #10896

Merged
melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-9889-40831897770-1
Oct 29, 2026
Merged

melodic-automation-lanes[bot] merged 1 commit into
mainfrom
work-resolve-issue/issue-9889-40831897770-1

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

Refs: #9889

Summary

Opened by the work-resolve-issue lane. The run's own summary:

Applies the ruff-format Windows Git Bash fixes to the other hook suites. Each probe-gate jq -r ... | read now pipes through tr -d '\r', so a Windows jq.exe's CRLF no longer leaves a CR on the module path node is given. Each spawn-budget census gate now also requires strace -qq -o /dev/null -e trace=execve true to succeed, so Git Bash's Cygwin strace skips the census case instead of failing it. Only test suites change; each touched plugin gets a bump: none fragment.

Remaining work

  • Done-when item 2: markdown-format.test.sh's 'the pre-commit entry names an approval marker in the git directory' case still fails on Windows Git Bash, and the issue says it is not covered here. Fix it or file it as its own issue. Lead (judgment, not checked on a host): markdown-gates.sh:286-291 conv

Not verified

  • The changed suites were not run here (the lane runs only its wrappers); the PR's CI runs them on Linux.
  • Done-when item 1 (each listed suite passes or skips its census case on Windows Git Bash, output posted from a /fleet:reach run) needs a run on a Windows host, which this lane cannot do.
  • Tidy skipped: the change is 23 files across 8 plugin areas, over the 10-file and 1-area tidy cutoffs.
  • The mapfile reads piped through sed (PostToolBatch/Stop ROW_ARGS in these suites) were left without a CR strip, matching ruff-format; the issue's results do not show them failing on Windows, and that was not checked on a host.

Fix

  • plugins/actionlint/hooks/actionlint-check.test.sh: tr -d '\r' on the SessionStart args read and the requires[0] TSV read
  • plugins/actionlint/hooks/actionlint-end-of-turn.test.sh: census gate requires a working Linux strace; skip note reworded
  • plugins/bash-format/hooks/bash-format.test.sh: tr -d '\r' on the SessionStart args read and the requires TSV loop; census gate requires a working Linux strace
  • plugins/bash-format/hooks/bash-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/biome-format/hooks/biome-format.test.sh: tr -d '\r' on the SessionStart args and requires[0] TSV reads; census gate requires a working Linux strace
  • plugins/biome-format/hooks/biome-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/go-format/hooks/go-format.test.sh: tr -d '\r' on the SessionStart args read; census gate requires a working Linux strace
  • plugins/go-format/hooks/go-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/powershell-format/hooks/powershell-format.test.sh: tr -d '\r' on the requires[0] TSV read and the SessionStart args read
  • plugins/powershell-format/hooks/powershell-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/typos-format/hooks/typos-format.test.sh: tr -d '\r' on the requires[0] TSV read and the SessionStart args read
  • plugins/typos-format/hooks/typos-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/markdown-format/hooks/markdown-format.test.sh: census gate requires a working Linux strace
  • plugins/markdown-format/hooks/markdown-format-end-of-turn.test.sh: census gate requires a working Linux strace
  • plugins/eol-normalizer/hooks/eol-normalizer.test.sh: tr -d '\r' on the row-gate args read (found in review); census gate requires a working Linux strace
  • .changes/{actionlint,bash-format,biome-format,eol-normalizer,go-format,markdown-format,powershell-format,typos-format}/test-9889-windows-git-bash-suites-<hex>.md: eight new bump: none fragments for the test-only change (written by hand because new-changelog-fragment refuses a detached HEAD)

Verification

The runner ran each check from the base copy against a1cbc5a:

  • scripts/check-changelog-fragments.sh --check: passed

The run reports:

  • check-changelog-fragments: passed, all 12 fragments under .changes/ valid (run before and after the review fix)
  • check-affected: 12 passed, 6 skipped (ruff: no .py; typos: not installed; 3 validate-plugins steps that run checked-tree code; changed-skills: none), 0 failed over 23 changed files (run before and after the review fix)
  • grep for command -v strace across the repo: the 12 sites without a working-strace probe are fixed; harness-ops hook-failure-audit, disk-hygiene run-python-hook and source-control worktree-gates-spawn-budget already probe strace before use; scripts/selection-audit.sh excluded as the issue says
  • read https: //cygwin.com/cygwin-ug-net/strace.html: Cygwin strace's options are -b -d -e -f -h -m -n -o -p -q -S -t -T -u -V -w; there is no -s, and -e is an argument-less toggle, so the probe strace -qq -o /dev/null -e trace=execve true fails under it, as the new comment says
  • fresh-context review subagent over the whole diff: one confirmed finding (eol-normalizer row-gate args read lacked the CR strip), now fixed; the other two were low and need no change (the probe matches ruff-format's; a Linux host whose strace cannot ptrace now skips the census instead of failing)
  • The lane run: https://github.com/melodic-software/claude-code-plugins/actions/runs/40831897770

Left out: the items under Not verified.

Related

#9889

Lane-Activity: work-resolve-issue/resolve-issue
@github-actions

Copy link
Copy Markdown
Contributor

claude-security-review reviewed a1cbc5a269d445ce20ccaf099e45645eaa29c31a: 0 finding(s), 0 as inline comments.

No security issues found in this pull request.

The 23 changed files are 15 hook test suites (plugins/*/hooks/*.test.sh) and 8 bump: none changelog fragments. None of them matches a trusted path.

  • Shell test suites: every edit does one of two things.
    • It appends | tr -d '\r' to a jq -r process substitution whose input is a repo-owned file (hooks.json, prerequisites.json) or a fixed in-script variable.
    • It adds && strace -qq -o /dev/null -e trace=execve true 2>/dev/null to the census gate, which runs a constant command and writes nothing.
  • Untrusted input and injection: neither edit feeds untrusted data into a command line, and neither adds an eval, a network call or a secret read. No shipped hook, manifest, workflow, token path or gate file changes.
  • Plugin manifests: no plugin.json or marketplace.json is touched, so no manifest <field> lines apply.
  • Instruction surfaces: none are touched.
  • PR text: the context file holds no embedded directives aimed at the review lane.
  • Spend: none.

critical-findings: 0

@github-actions

Copy link
Copy Markdown
Contributor

claude-review reviewed a1cbc5a269d445ce20ccaf099e45645eaa29c31a: 0 finding(s), 0 as inline comments.

No blocking or advisory findings in the 23 changed files. Everything changed is a test suite or a bump: none changelog fragment.

What I checked (read-only; I ran nothing):

  • The new | tr -d '\r' pipes sit on the jq process substitutions that feed read or while read. I grepped the touched suites for other jq-to-read loops and found none left unstripped. markdown-format.test.sh already strips the CR itself, at lines 113 and 118.
  • The census gate is the same in all 12 suites: command -v strace plus strace -qq -o /dev/null -e trace=execve true. Per the PR's cited Cygwin docs, a Cygwin strace fails that probe, so the census skips there. A Linux host whose strace can't ptrace also skips, where before it would fail. That is acceptable for a test gate. The skip note was reworded in each suite.
  • The eight changelog fragments are bump: none for test-only changes, and the PR reports check-changelog-fragments passing.
  • The PR body says Refs #9889 and there is no closing-issue section in the PR context. So there are no acceptance criteria to check this change against.
  • No manifest files changed, so there are no manifest <field> lines. I found no embedded instructions in the PR text.
  • No trusted-path files are in this diff.

Unverified, and the PR says so itself:

Spend: none beyond prepaid or subscription usage.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path armed native auto-merge at head a1cbc5a269d445ce20ccaf099e45645eaa29c31a.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants