-
Notifications
You must be signed in to change notification settings - Fork 2
test(markdown-format): SessionStart probe case failed once on Windows with only the jq notice #6011
Copy link
Copy link
Open
Labels
needs-humanHuman-in-the-loop required; autonomous sessions must not resolve items carrying this.Human-in-the-loop required; autonomous sessions must not resolve items carrying this.priority: lowNice-to-have, cosmetic, or speculative; opportunistic.Nice-to-have, cosmetic, or speculative; opportunistic.status: needs-decisionAwaiting a human or maintainer judgment call.Awaiting a human or maintainer judgment call.work-class: scopedA briefed fix or small feature; blast radius bounded by the brief, tests exist.A briefed fix or small feature; blast radius bounded by the brief, tests exist.
Description
Activity
Metadata
Metadata
Assignees
Labels
needs-humanHuman-in-the-loop required; autonomous sessions must not resolve items carrying this.Human-in-the-loop required; autonomous sessions must not resolve items carrying this.priority: lowNice-to-have, cosmetic, or speculative; opportunistic.Nice-to-have, cosmetic, or speculative; opportunistic.status: needs-decisionAwaiting a human or maintainer judgment call.Awaiting a human or maintainer judgment call.work-class: scopedA briefed fix or small feature; blast radius bounded by the brief, tests exist.A briefed fix or small feature; blast radius bounded by the brief, tests exist.
Problem
The markdown-format suite's "SessionStart probe with the kill switch unset" case (
plugins/markdown-format/hooks/markdown-format.test.sh:1979-1990) failed once on test-windows on a PR that did not touch markdown-format, then passed on the next head of the same branch. It expects the probe's notice to namemarkdownlint-cli2; the failing output named onlyjq.Evidence
12532bb89of feat(effort): phase effort advice, event-log content opt-in and typed OTEL columns, with the upstream record #5992, step "Test the markdown-format hook on Windows":PASS=166 FAIL=1 SKIPPED=4. Output:{"hookSpecificOutput":{... "additionalContext":"markdown-format: jq was not found on PATH. Hooks that need it will skip until it is installed. ..."}}, with nomarkdownlint-cli2line. The line just before readsbash.exe: warning: could not find /tmp, please create!.a65512646, passed test-windows.git diff --stat 12532bb89 a65512646 -- plugins/markdown-formatis empty.Likely cause (not confirmed)
run_probe_launcherruns the probe underenv -i PATH="$PROBE_BIN", which removesTMP/TEMP/TMPDIR; hence the/tmpwarning.probe-prerequisite.shreports each missing tool throughhook::notice_once "$plugin-$name", keyed on sessions1, which every probe case reuses. If notice-once state lands in a location shared across cases when the temp variables are gone, an earlier case can markmarkdownlint-cli2as already noticed, leaving onlyjq(which is never inPROBE_BINon Windows because the test links only/usr/local/bin,/usr/binand/bin). Where that state is written was not checked; #4612 (notice_once keys on agent) is in the same area.Impact
Low: 1 in 44 runs, and test-windows is not a required check. It still turns a PR's checks red and sends an agent to debug a plugin the PR did not change.
Proposed fix options
TMPDIRand whatever state roothook::notice_oncereads into theenv -icall) and a uniquesession_id.PROBE_BIN.Recommendation: confirm where
hook::notice_oncewrites underenv -ion Git Bash, then apply option 1. Basis: the failing output and the/tmpwarning above; the cause is a hypothesis until that check is done.Acceptance criteria
TMPDIR(or the notice state root) and a per-case session id insideenv -i./tmpwarning no longer appears in the step log.