Skip to content

Promote the Reference Ban and Its Gate to Main - #1696

Merged
ptr727 merged 2 commits into
mainfrom
develop
Sep 19, 2026
Merged

ptr727 merged 2 commits into
mainfrom
develop

Conversation

@ptr727

@ptr727 ptr727 commented Sep 19, 2026

Copy link
Copy Markdown
Owner

Promotes the reference ban from develop to main. The delta is one squash commit, 9ff38fe, and git diff --stat origin/main origin/develop is 41 files, 759 insertions, 167 deletions.

What it carries

Issue and pull request references were pervasive in this repository's code, comments and docstrings, and the rule that already forbade them named the category without naming the instance. Three parts, and none of them works alone.

The rule. comment-and-doc-style gains an "Issue, pull request, and commit references" section. No comment, no docstring and no instruction document names an issue, a pull request or a commit. A tracker, a history, a plan and a README outside the Skills trees keep their references, as do a commit message and a pull request body. Three reasons, in the order that decides them: a reference is a second lookup for a reader already holding the file, the lookup can be impossible where a repository is private, and a rationale block that takes one more citation per round is how a file comes to teach a house style the rules forbid. One record keeps a revision, a disproved-claims entry, whose subject is the revision itself. GOVERNANCE.md "Documentation Style Conventions" gains a ### References stub pointing at it.

The gate. A new default issue-ref prose rule reads the pattern-detectable half: a reference in a comment whose marker opens its line, in a Python docstring, and in instruction text. Not read, each for a stated reason: a commit, because a short SHA is the shape of a blob id, a version fragment and a fixture hash; a string literal, because a test builds the numbers it asserts against; a trailing line comment, because which mid-line marker opens a comment differs by language; a Markdown comment outside instruction text, because a README is narrative. A URI and a Markdown link destination are blanked before the scan.

The scrub. Every reference the tree held on those surfaces, replaced by the constraint it stood for or dropped where the reference was the whole of its value. The tree reads zero under every default rule.

Review record

The feature pull request ran three Copilot rounds and ten local adversarial passes. Round 2 stated reviewed=41 changed=41 findings=0, round 3 approved the final head, and all five threads were answered and resolved. Ten local passes found 13, 22, 7, 5, 6, 9, 7, 0 and 0.

Six items remain open and are recorded on #1694. Each is a claim about the gate rather than its behavior, and all six are hub-only: two clauses of issue_ref_findings' docstring, two sentences in scripts/README.md, and two test docstrings. The one open item in content other repositories carry was deleted before the merge.

Why it carries the comments label

The scrub edits comment lines and git diff --unified=0 counts a modified line as an added one, so comment-added reports them. The fleet's own caller also stands that rule down for a promotion of develop into the default branch, whose diff was reviewed where it landed.

Fixes #1689

…1694)

The existing comment rule banned historic narrative and cross-project
references without naming the instance, so a citation read as rigor rather
than as the thing the rule forbids, and nothing detected one. The tree then
taught the opposite of the rule at scale, which no rule text competes with
until the tree changes.

Three parts, and none of them works alone.

The rule now names an issue, a pull request, and a commit as what the ban
covers, with the surfaces it reaches and the reasons it exists: a reference
is a second lookup for a reader holding the file, the lookup can be
impossible where a repository is private, and a rationale block that takes
one citation per round teaches a house style the rules forbid. One record
keeps a revision, a disproved-claims entry, whose subject is the revision
itself.

The prose gate carries a new default rule reading the pattern-detectable
half, a reference in a comment whose marker opens its line, in a Python
docstring, and in instruction text. A commit is not a shape a gate can read,
a string literal is not read because a test builds the numbers it asserts
against, and a URI fragment and a Markdown link destination are blanked
before the scan.

And every reference the tree already held on those surfaces is replaced by
the constraint it stood for, or dropped where the reference was the whole of
its value.

A README, a tracker, a history, and a plan keep their references, as do a
commit message and a pull request body.
Copilot AI lite review requested due to automatic review settings September 19, 2026 16:27
@ptr727 ptr727 added the comments Permits the comment lines the pull request adds or edits, which the prose gate otherwise refuses label Sep 19, 2026
@coderabbitai

coderabbitai Bot commented Sep 19, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Repository: ptr727/ProjectTemplate/.coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: 350ed43a-b0b2-4bde-83b6-0936a501efe2


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI 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.

Copilot review overview

🟡 Changes recommended

One newly added doc sentence in scripts/README.md appears to make a factual claim that conflicts with the file’s intentionally reference-bearing narrative role.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 1 Low severity

Open (1)
What changed in this PR

Promotes the repository-wide ban on issue / pull request / commit references (on governed prose surfaces) to main by introducing the issue-ref prose-gate rule, documenting the policy in governance + skills, and scrubbing previously cited references from comments/docstrings/instruction text.

Changes:

  • Add issue-ref to the prose gate default rules, including parsing for leading comments, Python docstrings, and instruction Markdown, plus comprehensive unit tests.
  • Update governance/docs/runbooks to explicitly state the reference ban and how/where it is enforced.
  • Scrub existing references from governed surfaces across scripts/spec/docs and propagate skill distributions/digests.
File Description
STANDUP.md Removes an inline issue reference from onboarding prose.
spec/​validate.py Scrubs issue references from explanatory comments/docstrings.
spec/​audit.py Scrubs issue references from module/docstring commentary and selftest comments.
scripts/​tests/​test_tooling_encoding.py Scrubs an issue reference from a test comment.
scripts/​tests/​test_spec_validate.py Scrubs issue references from comments/docstrings in spec validator tests.
scripts/​tests/​test_release_guards.py Scrubs issue references from explanatory comments/docstrings.
scripts/​tests/​test_prose_lint.py Adds a full test suite for the new issue-ref rule and scrubs existing references.
scripts/​tests/​test_pr_review.py Scrubs issue/PR references from comments/docstrings while preserving test intent.
scripts/​tests/​test_handoff.py Scrubs issue references from docstrings while preserving test semantics.
scripts/​tests/​test_canonical_review.py Scrubs issue references from a test docstring.
scripts/​README.md Documents the new issue-ref rule and its intended scope/carve-outs.
scripts/​pr_review.py Scrubs issue/PR references from commentary while preserving behavior documentation.
scripts/​handoff.py Scrubs an issue reference from command commentary.
scripts/​canonical_review.py Scrubs issue references from module documentation prose.
scripts/​build_dist.py Scrubs an issue reference from commentary about digest layout.
OPERATIONS.md Updates local-run guidance to include issue-ref in the prose checks list.
host-setup/​windows/​install-tools.ps1 Scrubs an issue reference from a PowerShell comment.
host-setup/​linux/​install-tools.sh Scrubs an issue reference from a shell comment.
GOVERNANCE.md Adds a “References” subsection and updates communication guidance placeholders.
catalog/​snippets/​workflows/​test-pull-request.yml Scrubs an issue reference from workflow snippet comments.
AUDIT.md Scrubs issue references from audit prose while keeping the operational guidance.
.github/​workflows/​validate-task.yml Scrubs an issue reference from workflow comments.
.github/​skills/​session-handoff/​SKILL.md Updates generated skill content to match the new placeholder form.
.github/​skills/​pr-review-conduct/​SKILL.md Updates generated skill content to remove issue references.
.github/​skills/​comment-and-doc-style/​SKILL.md Updates generated skill content with the new “references” policy section.
.github/​skills/​agent-conduct/​SKILL.md Updates generated skill content to match the new placeholder form.
.github/​actions/​repo-gate/​repo_gate.py Rewords metric documentation to remove an issue reference and clarify counts.
.github/​actions/​prose-gate/​prose_lint.py Implements issue-ref rule and extends comment extraction to preserve raw markers.
.github/​actions/​prose-gate/​action.yml Scrubs an issue reference from action commentary.
.claude-plugin/​fleet-skills/​skills/​session-handoff/​SKILL.md Updates plugin-distributed skill content to match the new placeholder form.
.claude-plugin/​fleet-skills/​skills/​pr-review-conduct/​SKILL.md Updates plugin-distributed skill content to remove issue references.
.claude-plugin/​fleet-skills/​skills/​comment-and-doc-style/​SKILL.md Updates plugin-distributed skill content with the new “references” policy section.
.claude-plugin/​fleet-skills/​skills/​agent-conduct/​SKILL.md Updates plugin-distributed skill content to match the new placeholder form.
.claude-plugin/​fleet-skills/​.source-digests/​session-handoff Updates digest after skill content change.
.claude-plugin/​fleet-skills/​.source-digests/​pr-review-conduct Updates digest after skill content change.
.claude-plugin/​fleet-skills/​.source-digests/​comment-and-doc-style Updates digest after skill content change.
.claude-plugin/​fleet-skills/​.source-digests/​agent-conduct Updates digest after skill content change.
.agents/​skills/​session-handoff/​SKILL.md Updates source skill include output to match the new placeholder form.
.agents/​skills/​pr-review-conduct/​SKILL.md Updates source skill content to remove issue references.
.agents/​skills/​comment-and-doc-style/​SKILL.md Adds the new “Issue, pull request, and commit references” section (source of truth).
.agents/​skills/​agent-conduct/​SKILL.md Updates source skill include output to match the new placeholder form.

💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread scripts/README.md Resolved
…1697)

`scripts/README.md`'s `issue-ref` paragraph ended "...keep their references, which is why this file's own are clean", which reads as a claim that the file carries no reference, and that is not true of it. The intended reading was that its references break no rule, which the clause before it already establishes by naming a README outside the Skills trees as narrative.

Replaced by "this file among them", which states the membership the carve-out turns on and claims nothing about the file's contents. A narrative file may carry as many references as it needs, so a count is the wrong thing to assert about one either way.

Raised on the develop to main promotion.
Copilot AI review requested due to automatic review settings September 19, 2026 16:42

Copilot AI 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.

Copilot review overview

🟢 Approval recommended

The new issue-ref default rule is implemented with targeted parsing and is covered by dedicated tests, and the remaining changes are consistent reference scrubs and documentation updates with no functional regressions identified.

Review effort: Lite
Findings: None

Resolved since last review (1)

@ptr727

ptr727 commented Sep 19, 2026

Copy link
Copy Markdown
Owner Author

Merge Gate evidence for the current head, a409f818.

Coverage, proved rather than read off the digest, since round 2's body carries no counts and pr_review.py reports coverage=unstated:

  • Round 1 at 9ff38fe stated full coverage and raised the one finding.
  • Round 2 at a409f818 recommends approval with no findings.
  • git diff --stat 9ff38fe a409f81 is one file, one line: the scripts/README.md sentence the finding was about.

So the only content that moved after the full-coverage round is the content round 2 read, and it is the content the finding asked to change.

The rest of the gate: review on head yes, 1 thread and 0 unresolved, 0 suppressed, no refusal, 8/8 checks, mergeable CLEAN. The feature pull request behind this one ran 3 Copilot rounds and 10 local adversarial passes before merging.

Six items remain open and recorded on #1694. Each is a claim about the gate rather than its behavior, and all six are hub-only: two clauses of issue_ref_findings' docstring, two sentences in scripts/README.md, and two test docstrings. The one open item in content other repositories carry was deleted before that merge. #1695 carries comment-added's own version of the same inexactness, which predates this work.

Stopping here. Merging main and dispatching the release each need their own go-ahead.

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

Labels

comments Permits the comment lines the pull request adds or edits, which the prose gate otherwise refuses

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Scrub Issue and Pull Request References From Code, Comments, and Docstrings

2 participants