Skip to content

fix(pr-convention-policy): read the ci-workflows#815 check-contract shape - #825

Merged
kyle-sexton merged 3 commits into
mainfrom
fix/lockstep-drift-815
Oct 20, 2026
Merged

kyle-sexton merged 3 commits into
mainfrom
fix/lockstep-drift-815

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Oct 20, 2026 •

Copy link
Copy Markdown
Member

Refs: melodic-software/ci-workflows#736

Summary

check-pr-convention-copies fails on every standards PR and on main
(job).
ci-workflows#815 rewrote two parts of
check-contract/run.sh that the static parsers in lockstep-drift.mjs anchor on. The behavioral
tests still passed; only the text parsers broke:

  • drift: gate composite: closing-keyword / no-issue-marker match expressions not found in run.sh
  • drift: gate composite (negated closers): negation_trigger's window, "not only" exception, trigger words, or suffix test not found in run.sh

Fix

Verification

  • npm run lint:pr-convention-copies against live ci-workflows main: every copy matches policy.json.
  • checkPinnedComposite on each run.sh, with that ref's action.yml, ran locally: 0 findings for
    ci-workflows main, for Add uv to the dependabot auto-merge ecosystems or record why not #820's head f43d19ee492d3f8f53e72109023cb50071f92b0c, and for the
    pre-sync: let claude-code-plugins set merge=union on six append-only list files #815 parent of cc7613fbf8bacca72700d6498c32145c05fe1f09.
  • New mutation test: passes locally.
  • npm run test:pr-convention-lockstep: not green locally. The host was overloaded (load average
    83 on 32 cores), so the hook validator's behavioral harness hit its 10s limit
    (the validator did not finish within 10s). That harness also threw one spawnSync bash EPIPE.
    Neither involves the composite parsers. CI's hermetic run on this PR is the authoritative result.
  • Pre-commit hooks passed: editorconfig, typos, biome, gitleaks.

Related

🤖 Generated with Claude Code

kyle-sexton and others added 2 commits October 20, 2026 16:20
…hape

ci-workflows#815 rewrote two parts of check-contract/run.sh that the
lockstep static parsers anchor on, so check-pr-convention-copies failed
on every standards PR and on main:

- scan_line applies closing_regex with one gsub pass over the lowercased
  line (marked = lower; gsub(closing_regex, "\n&\n", marked); split)
  instead of a match(chunk, closing_regex) loop.
- negation_trigger scans backward and stops at the fifth word boundary
  (++seen == 5) or at . ! ? ; , instead of cutting at the punctuation
  and keeping the last five words (first = (count > 5) ...).

The parsers now accept either shape, and each form must keep every
anchor: the lowercased source, the closing_regex application, the
window size, the five punctuation stops and the window slice. The
pre-#815 shape stays accepted for consumer pins and for
ci-workflows#820, whose head still carries it.

Adds the #815 run.sh as a fixture, with tests that it passes and that
each of its anchors, mutated away, is reported as drift.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…behavioral layer

The static negation-window check anchored on the five punctuation stops,
which made an existing test fail: it asserts that adding ":" to the set is
behavioral drift only. The window size and the window slice stay anchored.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 20, 2026 20:32
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-20T20:33:15.057309Z dd68984 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

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

No findings. The only change since the last review (dd68984) is to components/pr-convention-policy/fixtures/lockstep/check-contract-run-bounded-scan.sh.txt. The API gave no patch for it, so I read the git index instead.

  • The file is now mode 100755, the same as its sibling fixtures check-contract-run.sh.txt and check-contract-run-literal-ref.sh.txt. The commit message calls it a mode-only change, and the index data fits that.
  • I did not confirm the file's content is unchanged from dd68984. A git show on the commit was refused, so the diff was not run.
  • I did not run the fixture tests or npm run lint:pr-convention-copies.
  • The PR body's verification claims are the author's and I did not check them.
  • The PR body is data and contains no embedded directives. Refs: melodic-software/ci-workflows#736 links an issue without closing it, so there are no closing-issue criteria to check.

@github-actions

github-actions Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

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

Security review (incremental, head b25ed4e): no findings.

The only change since dd68984 is to components/pr-convention-policy/fixtures/lockstep/check-contract-run-bounded-scan.sh.txt. The diff is 0 insertions and 0 deletions, so it is a file-mode change from 100644 to 100755 (the commit message also says "mark ... executable"). The file content is unchanged.

  • Execution: The fixture is a .txt data file. The only reference I found is lockstep-drift.test.mjs:73, which reads it as text with readFixture. Nothing executes it, so the executable bit adds no execution path.
  • Siblings: Two of the sibling fixtures (check-contract-run.sh.txt, check-contract-run-literal-ref.sh.txt) are already 100755, so this matches the existing convention.
  • Instruction surface: The change does not delete, narrow or soften any guardrail, rule, hook or allowlist.

I did not check whether the 100755 mode is needed. That is a convention question, not a security one.

Everything else in the PR was reviewed at dd68984 and is unchanged since.

…xecutable

It carries a shebang, and its sibling run.sh fixtures are already 100755.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton
kyle-sexton merged commit bd7172d into main Oct 20, 2026
22 checks passed
@kyle-sexton
kyle-sexton deleted the fix/lockstep-drift-815 branch October 20, 2026 20:47
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.

1 participant