Skip to content

feat(corrections): count Codifies: records with codify count-checks - #16363

Merged
kyle-sexton merged 8 commits into
mainfrom
work-resolve-issue/issue-15650-43729451450-1
Nov 15, 2026
Merged

kyle-sexton merged 8 commits into
mainfrom
work-resolve-issue/issue-15650-43729451450-1

Conversation

@melodic-automation-lanes

@melodic-automation-lanes melodic-automation-lanes Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Closes #15650

Summary

Adds /corrections:codify count-checks, a read-only count of the checks that merged changes record with a Codifies: line in the pull request body.

  • It reads the default branch's first-parent history with git log, calls no forge and writes no file.
  • It prints one row per week or month and a window row: new and cumulative blocking and advisory counts, then a column for each rung that occurs. It prints no ratio.
  • A record counts only as a whole line at column 0. An attempted record in any other place (a list item, a code span, a quoted or indented line, trailing prose, a malformed or placeholder line, a guidance or human-review rung, an unknown rung, make-impossible marked advisory) is listed as not counted with its commit and reason. A line that only mentions the key in prose is ignored.
  • The default window opens at the earliest commit day that holds a counted record, a reverted record or an attempted record.
  • Promotion: an advisory record is keyed by the pull request that landed it (the number at the end of its squash subject) and its rung. A later blocking line whose source is that pull request moves the check to the blocking column, counted once. Each promotion of a same-source, same-rung record needs its own commit; a repeated promoting line is listed as not counted.
  • Reverts: a commit whose subject starts with Revert and that says This reverts commit <sha> or Reverts owner/repo#<n> for this repository removes the record and lists it. A blocking record whose advisory origin was reverted is counted as a new blocking check and listed.
  • Rung ids and tiers are parsed from the plugin's ladder copy, so the counted set follows the ladder.
  • Codify's proposal for a checking rung or make-impossible now holds the literal record line and its task-list item form.
  • The issue lane's linkageLines copies a whole Codifies: record of at most 72 characters from a task-list item that names the pull request body, so both body builders carry it. It never copies one from the run's text.
  • The enforcement ladder is at 3.1.0: the "Compiler or type settings" and "Tests" rows now have the ids compiler-setting and behavior-test, and the five plugin copies are regenerated.

Remaining work

Not verified

  • No model eval ran on the changed codify skill.
  • The argument hint drops reviews' [--pr <n>] and note's [--applied] to fit the 100-character budget; the Actions table keeps the full forms.
  • count-checks counts a matching record longer than 72 characters; only the issue lane enforces that cap.
  • With no origin remote URL to read, a revert that names a pull request is matched by number alone, and the output says so.
  • The codify-proposal-names-the-fix eval's grader on main accepts action-guard, harness-setting or architecture-test for its row 6 and was left unchanged; it does not accept behavior-test.

Fix

  • plugins/corrections/scripts/count-checks.mjs: the counter.
  • plugins/corrections/scripts/count-checks.test.sh: fixture-repository tests (81 checks) with hand-derived expected rows.
  • plugins/corrections/skills/codify/actions/count-checks.md: the action.
  • plugins/corrections/skills/codify/SKILL.md: the action in the argument hint, Actions table, action words, allowed-tools, proposal contents and Boundary.
  • plugins/corrections/skills/codify/reference/finding-classes.md: the Record line section (grammar, blocking and advisory, promotion, task-list item form).
  • plugins/corrections/README.md: the action and script rows.
  • .github/scripts/work-resolve-issue/report-outcome.mjs and its test: linkageLines carries the issue's record line.
  • docs/contracts/enforcement-ladder/README.md and CHANGELOG.md: 3.1.0 and the two ids; the five plugin copies regenerated by sync-shared-copies.
  • docs/skill-cheat-sheet.md: the codify row.
  • Changelog fragments for the five plugins.

Verification

Related

#15650

🤖 Generated with Claude Code

Lane-Activity: work-resolve-issue/resolve-issue
@melodic-automation-lanes

melodic-automation-lanes Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor Author

Unattended merge: native auto-merge leaves this pull request unarmed at head 28e596d65d9229b5837427c39160b1ee4bce8cb1. No person needs to act: a lane clears this reason, and the next scheduled run judges it again.

pr-merge's gate refuses its verifier verdict (verify:missing)

@github-actions

Copy link
Copy Markdown
Contributor

Lane run report

Field Value
Activity pr-refine/fix-docs
Model rung 0
Leg handoff
Run job success
Activity step success
Commits pushed none (read lane)
Run 43731586018

Failed GitHub API calls

Method Path Status
GET /repos/{repo}/git/ref/tags/* 404

@github-actions

github-actions Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed 28e596d65d9229b5837427c39160b1ee4bce8cb1: read 1 of 1 changed file(s); 0 finding(s), 0 as inline comments.

Security review: PR #16363, incremental (d82bd05 → 28e596d)

No security issues found in this push.

critical-findings: 0

This lane had already reviewed an earlier head, so this pass was blocking only: it would report only CRITICAL and IMPORTANT findings. I read the whole incremental diff, which is 1 of 1 listed files. That file is not on a trusted path.

plugins/corrections/scripts/count-checks.test.sh: the push changes one test fixture commit message from **Codifies:** #13 rung=action-guard blocking to **Codifies:** #13 action-guard blocking, and updates the matching grep -qF assertion. The fixture runs in a temporary test repository. The assertion uses a fixed-string grep over the captured output. The push adds no shell interpolation of untrusted input, no network access and no file writes outside the test repository.

Other checks

  • No plugin.json or marketplace.json changed, so there are no manifest items.
  • Nothing changes trusted actors, token scope, the kill switch, merge holds or a standing instruction.
  • The push adds no prepaid spend and nothing that could create a charge.

@github-actions

github-actions Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed 28e596d65d9229b5837427c39160b1ee4bce8cb1: read 1 of 1 changed file(s); 0 finding(s), 0 as inline comments.

Code review: PR #16363, incremental pass from d82bd05 to 28e596d (blocking only)

No blocking findings. This lane already reviewed an earlier head (blocking only: yes), so this pass reports only blocking findings and manifest flags. I read the whole incremental diff, which changes one file: plugins/corrections/scripts/count-checks.test.sh.

What I checked

  • Fixture 3b-1b (count-checks.test.sh#L302-L305) now uses the emphasis line **Codifies:** #13 action-guard blocking, which has no rung=. The test no longer gets a pass from RUNG_VALUE, so only ATTEMPT can list the line (count-checks.mjs#L33-L36). I traced it by hand:
    • Emphasis line: in Codifies: followed by **, a space and #1, [*][ \t](?:#[0-9]|…)` matches. The line is not at column 0, so it is listed as not counted.
    • Quoted grammar: Codifies: <#n… and rung=<id> match neither regex, so it is still skipped.
    • Repeated advisory line: it is still listed.
    • Total: not counted: 2 still holds.
    • Assertion on line 317: it matches the new fixture text.
  • I did not run the tests, because this lane has no shell. Any claim that they pass is the author's and is unverified.

Not checked or not applicable

  • Plugin manifests: none changed in this push.
  • Closing issue: this push changes only a test fixture. The acceptance criteria assessed in the previous review are unaffected.
  • Spend: none. The test exercises local git history only.

Verifier dropped 0 of 0 candidates.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path armed native auto-merge at head 5ff5060385d3ec2ae973eac2a1208dbeb477598d, the head its arming checks judged.

@melodic-automation-lanes

melodic-automation-lanes Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor Author

Verification evidence for 28e596d

The verifier passed this head. The capture artifact holds the capture summary, which says whether the capture ran, and any screenshot or video that passed the mask check; this comment uploads no file.

Capture artifact: pr-capture-16363-28e596d65d9229b5837427c39160b1ee4bce8cb1, expires on 2026-12-15.

One comment per pull request, updated in place for each new head.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Merge-Risk: max=HIGH demote=true head=5ff5060385d3ec2ae973eac2a1208dbeb477598d rubric=9.2.4 rater=claude-opus-5-5 checker=claude-opus-5-5

@github-actions

Copy link
Copy Markdown
Contributor

Lane run report

Field Value
Activity pr-unblock/resolve-conflicts
Model rung 0
Leg handoff
Run job success
Activity step success
Commits pushed none (read lane)
Run 43732833503

Failed GitHub API calls

Method Path Status
GET /repos/{repo}/git/ref/tags/* 404

Lane-Activity: pr-unblock/resolve-conflicts
@github-actions

Copy link
Copy Markdown
Contributor

Lane run report

Field Value
Activity pr-unblock/apply-conflict-patch
Model rung 0
Leg base
Run job success
Activity step success
Commits pushed a36c05e
Run 43732833503

Failed GitHub API calls

Method Path Status
GET /repos/{repo}/git/ref/tags/* 404

@melodic-automation-lanes
melodic-automation-lanes Bot added this pull request to the merge queue Nov 15, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Nov 15, 2026
@kyle-sexton kyle-sexton added the do-not-merge Hard merge gate: do not merge while applied. label Nov 15, 2026
kyle-sexton and others added 3 commits November 15, 2026 11:42
…sue-15650-43729451450-1

# Conflicts:
#	plugins/corrections/evals/codify-proposal-names-the-fix/case.yaml
…every Codifies: line

- A blocking record promotes an advisory one when its source is the pull
  request that landed the advisory record (that commit's `(#p)` subject
  suffix) and the rung matches, so a session-sourced advisory check made
  blocking counts once, and two checks sharing an issue number count twice.
- Every line naming `Codifies:` off column 0 (the task-list item form,
  code spans, prose) is listed as not counted with its reason.
- History is read with `git log --first-parent`.
- `Reverts owner/repo#n` reverts only when owner/repo is origin's; with no
  origin URL the number alone is matched and the output says so.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@kyle-sexton kyle-sexton removed the do-not-merge Hard merge gate: do not merge while applied. label Nov 15, 2026
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 15, 2026
@kyle-sexton
kyle-sexton removed this pull request from the merge queue due to a manual request Nov 15, 2026
@kyle-sexton kyle-sexton added the do-not-merge Hard merge gate: do not merge while applied. label Nov 15, 2026
kyle-sexton and others added 3 commits November 15, 2026 12:20
…rted promotion origins

count-checks listed every line that merely mentioned Codifies:, a commit
subject and prose included, and opened a default window at the first such
mention. It now lists a line off column 0 only when it looks like an
attempted record (the text after Codifies: starts with #<digit>, session
or <, or the line holds rung=), and opens the window only at a counted,
reverted or record-like line.

A repeated line in one commit message still counts once, and the repeat
is now listed as not counted with its reason, so a second promotion of a
same-source same-rung advisory record is visible; finding-classes.md says
each such promotion needs its own commit. A blocking record whose
advisory record was reverted is listed as a new blocking check with the
reverted record and its reverter. The number-only revert note now reads
true when origin exists but its URL names no owner/repo.

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

A malformed line at column 0 older than every record again opens the
default window and is listed. A record written with emphasis on the key
is listed, a quoted grammar with placeholders is not, and a repeated
line carries the promotion hint only when it is a blocking record.

Refs: #15650

Co-Authored-By: Claude Fable 5.2 <[email protected]>
@kyle-sexton kyle-sexton removed the do-not-merge Hard merge gate: do not merge while applied. label Nov 15, 2026
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 15, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Nov 15, 2026
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 15, 2026
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

The unattended merge path armed native auto-merge at head 28e596d65d9229b5837427c39160b1ee4bce8cb1, the head its arming checks judged.

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

Merge-Risk: max=HIGH demote=true head=28e596d65d9229b5837427c39160b1ee4bce8cb1 rubric=9.2.4 rater=claude-opus-5-5 checker=claude-opus-5-5

@kyle-sexton
kyle-sexton removed this pull request from the merge queue due to a manual request Nov 15, 2026
@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 15, 2026
Merged via the queue into main with commit e098563 Nov 15, 2026
84 checks passed
@kyle-sexton
kyle-sexton deleted the work-resolve-issue/issue-15650-43729451450-1 branch November 15, 2026 18:23
@github-actions github-actions Bot added the merge-path: owner-agent Post-merge accounting record (README.md, Merge paths) label Nov 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-path: owner-agent Post-merge accounting record (README.md, Merge paths)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Count corrections that became checks and generate the rule-to-enforcer inventory

1 participant