Skip to content

feat(source-control): run remove-comments in PR prep and tell implementers to write comments clean - #12790

Merged
kyle-sexton merged 3 commits into
mainfrom
work-resolve-issue/issue-12548-41590709120-1
Nov 3, 2026
Merged

kyle-sexton merged 3 commits into
mainfrom
work-resolve-issue/issue-12548-41590709120-1

Conversation

@melodic-automation-lanes

Copy link
Copy Markdown
Contributor

Closes #12548

Summary

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

Pull-request prep now runs /code-tidying:remove-comments --pipeline --added-since <remote>/<base-branch> as step 2 of §1.4, after /simplify and before the simplify diff is reviewed, so the pipeline default posture necessary finally has a caller. An unattended run (--unattended, or a loop lane, CI lane, dontAsk session or dispatched worker, matching ready-for-review §2.5.1) applies no comment edit unless the consuming project's instructions pre-approve it, and otherwise runs the pass in report mode and lists the proposals in the 1.6 report. The pre-PR ordering contract and session-flow's pre-PR sequence now name the comment pass inside step 4, and both implementer agents carry one line to write comments clean while authoring, with tests documenting steps in assertion and log strings. On the human comment about what an unattended necessary run may delete: I re-checked it. Under necessary the pass deletes warnings about this repository's own code, including the security warning in the real-statusline-stamp eval, and stages each one in its report. For that reason prep's unattended default is report-only, and the step says so in the line a person reads before pre-approving. Design choices, with the evidence: the pipeline caller is prep §1.4, the step that runs /simplify; the absorption table's row 34 places the pass after /simplify and before review. The pre-approval signal is the consuming project's instructions, the same kind of signal create's --draft 'ready flip reserved for a person' already reads, so no new setting was added.

Not verified

  • tidy skipped: the change touches 5 areas (source-control, session-flow, implementation, code-tidying, docs/contracts), over the 1-area cutoff
  • plugins/implementation/scripts/agent-contract-sync.test.sh and the other test suites were not run here (this lane runs no checkout tests); left to the PR's CI. The review subagent compared the two contract blocks by reading them
  • ai-slop:audit and docs-hygiene:audit-noise were not run as skills over the changed markdown (this lane loads them only as tidy passes, and tidy was skipped). The changed lines were read for em dashes and residue by hand and in the review
  • skill-quality:check ran only through check-changed-skills (the lane's form, with markdownlint and script tests skipped); the full markdownlint run is left to the PR's CI

Fix

  • plugins/source-control/skills/pull-request/reference/prep.md: §1.4 gains step 2, the comment pass (--pipeline --added-since, report-only when unattended without pre-approval, a not-run line when code-tidying is absent); later steps are renumbered; the §1.1 code row and the §1.6 report name the…
  • plugins/source-control/skills/pull-request/SKILL.md: the prep, prep quick and prep simplify-only rows name the comment pass
  • plugins/source-control/skills/pull-request/templates/checklist.md: the Phase 1 line names the comment pass
  • docs/contracts/pre-pr-ordering/README.md: order step 4 reads 'Simplify, then the comment pass (/code-tidying:remove-comments)'
  • plugins/session-flow/skills/workflow/context/pre-pr.md: step 4 runs the comment pass after simplify, in report mode when unattended unless pre-approved
  • plugins/implementation/agents/implementer.md: new 'Write comments clean while authoring.' line inside the shared contract block
  • plugins/implementation/agents/scoped-implementer.md: the same line, so the contract blocks stay identical
  • plugins/code-tidying/skills/remove-comments/actions/remove.md: the report-mode note names the form prep now runs (report --pipeline --added-since <base>)
  • plugins/code-tidying/skills/remove-comments/actions/audit.md: dropped the stale claim that prep runs audit --added-since
  • .changes/source-control/work-resolve-issue-issue-12548-41590709120-1-3dd5a883.md: minor fragment
  • .changes/session-flow/work-resolve-issue-issue-12548-41590709120-1-1fd1d340.md: minor fragment
  • .changes/implementation/work-resolve-issue-issue-12548-41590709120-1-ae5aded9.md: minor fragment
  • .changes/code-tidying/work-resolve-issue-issue-12548-41590709120-1-f2ea1cdd.md: patch fragment

Verification

The runner ran each check from the base copy against 86b6d0c:

  • scripts/check-changelog-fragments.sh --check: passed
  • scripts/check-changed-skills.sh --merge-base: passed

The run reports:

  • read https: //github.com/melodic-software/claude-code-plugins/issues /7585#issuecomment-6292628965: rows 33, 34 and 36 of the absorption table. Row 33: runs before review in the PR flow. Row 34: order in the pipeline config, after /simplify and before review; apply under the team default posture,…
  • check-changelog-fragments: all 12 fragments valid (run before and after the review fixes)
  • check-changed-skills: remove-comments, workflow and pull-request PASS with 0 errors (warnings only, all from before this change)
  • check-affected: 11 passed, 7 skipped over 13 changed files
  • fresh-context review subagent over the whole diff: 3 findings (prep's unattended definition left out --unattended; remove.md and audit.md named a stale prep form; the pull-request checklist template left out the pass). All 3 fixed. It confirmed the remove-comments syntax, the --pipeline to…
  • The lane run: https://github.com/melodic-software/claude-code-plugins/actions/runs/41590709120

Left out: the items under Not verified.

Related

#12548

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

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

Copy link
Copy Markdown
Contributor Author

Unattended merge: native auto-merge leaves this pull request unarmed at head 74339fe25f28d6d1bc4b42fda6e9b2fac17452fa. The lanes clear this reason on their own; the next scheduled run judges it again.

pr-merge's gate holds it on its risk score (evidence-unbound:claude-review: not bound:
  rerun-not-allowed; evidence-unbound:claude-security-review: not bound: rerun-not-allowed)

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

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

Security review: PR #12790, incremental (74339fe → 40cb6b1)

I found no security issues. This round covers one file, plugins/session-flow/skills/workflow/context/pre-pr.md, and I read every hunk of its change. It does not match any TRUSTED PATHS glob.

What I checked:

  • Step 4 of pre-pr.md (L19-L23). The only edit adds one fallback: when the code-tidying plugin is not enabled, the step reports comment pass not run: code-tidying plugin not enabled.
    • The step still runs the comment pass in report mode when unattended, unless the project pre-approves comment edits.
    • Step 5 (review the simplify diff) and step 6 (re-test after simplify) are unchanged.
  • Instruction-surface lens. The edit deletes, narrows or softens no rule. It only adds an explicit report for the case where the pass is skipped, which makes the skip visible.
  • Plugin manifests. None changed.
  • Embedded text. The PR context has no instructions aimed at this lane.

Prior findings. The earlier round posted 0 findings, so there is nothing to repeat. The round cap (3) has not been reached.

critical-findings: 0

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

claude-review: 1 inline finding(s) on 74339fe25f28d6d1bc4b42fda6e9b2fac17452fa; the summary is in this lane's pull request comment.

claude-lane: claude-review

@github-actions

github-actions Bot commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

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

Code review (incremental): PR #12790, 74339fe2 → 40cb6b1e

Scope: the one file this push changed, plugins/session-flow/skills/workflow/context/pre-pr.md. I read its whole hunk. The incremental diff touched 1 of 1 listed files.

What the push changed. Step 4 of the pre-PR sequence now has a fallback for when the code-tidying plugin isn't enabled: "without that plugin, report comment pass not run: code-tidying plugin not enabled" (pre-pr.md L19-L23).

  • The fallback sits in the same sentence as the "when that plugin is enabled" condition, so it satisfies seam-phrasing item 2.
  • The not-run string matches prep.md §1.4 word for word (prep.md L76).
  • The rest of the step is unchanged: report mode when unattended unless the project pre-approves.

This resolves my earlier inline finding (settled thread, fixed in 40cb6b1e). I found nothing new in this change.

Restated summary finding (advisory; summary findings carry over each round): no test could fail if issue #12548's criteria broke. This push added no eval.

  • plugins/source-control/skills/pull-request/evals/evals.json still has no case for the comment pass (L275, L500).
  • Two eval cases are missing:
    • "Unattended without pre-approval, that step runs in report mode." This is the safety-relevant one. An eval should check that an unattended prep run calls report --pipeline --added-since and applies no comment edit.
    • The not-run fallback. An eval should check that prep reports comment pass not run: code-tidying plugin not enabled when the plugin is absent.
  • For criterion 3, agent-contract-sync.test.sh only checks that the two contract blocks are identical, so deleting the write-clean line from both would still pass.

Other notes

  • Round 2 of 3; the round cap did not apply.
  • I ran no tests or evals. The PR's own verification is author-claimed and unverified here.
  • I found no embedded instructions in the PR context, settled-threads or prior-findings files.
  • No spend or cost change.

Lane-Activity: pr-unblock/address-feedback
Lane-Thread: PRRT_kwDOTCGFQM6zLPis
@melodic-automation-lanes

Copy link
Copy Markdown
Contributor Author

pr-unblock / address-feedback finished round 1 of max 4 on 40cb6b1.

@kyle-sexton
kyle-sexton added this pull request to the merge queue Nov 3, 2026
Merged via the queue into main with commit ad71bc9 Nov 3, 2026
46 checks passed
@kyle-sexton
kyle-sexton deleted the work-resolve-issue/issue-12548-41590709120-1 branch November 3, 2026 16:05
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.

code-tidying: run remove-comments in the PR pipeline and add the write-clean line

1 participant