docs(ac-closure-check): the doc comment follows the scope it describes #979

Merged
bosun merged 1 commit from i/965-doc-comment-follows-the-scope into main 2026-08-26 20:06:38 +02:00
Owner

Refs frankenbit/release-toolkit#965. Comment only, no behaviour change.

Intended-targets: none — this PR declares no closes.

The gate told the truth and the file describing it did not

#977 updated the runtime disclosure when the commit-message scan shipped. The doc comment eleven lines above it was not updated, and still read:

"Reads the PR BODY only — not individual commit messages, which can also carry a close-keyword Forgejo would honor."

That sentence was false the moment the scan landed.

🔑 Why my own diff review could not catch it

The stale sentence sat outside the diff that made it false. I edited the disclosure string; the contradicting comment was untouched, therefore invisible in the hunk. This is the correction-completeness shape on my own work, one commit after shipping the correction — the half you edited is the half you re-read.

How it surfaced — and the check that found it

While re-deriving #965's ACs from main in order to tick them. AC5 asks whether the disclosure names the new boundary accurately, and I checked two things rather than one:

new wording PRESENT      ✅   ← what I would have checked
retired wording ABSENT   ❌   ← what actually found it

Presence is a weaker property than integrity. Confirming the new text is there says nothing about whether the old text is still there contradicting it, and the first check alone would have ticked AC5 on a file that lies.

The retraction quotes what it retracts, so the fix is checkable rather than asserted.

Verification

20 go packages ok
register-check · fragment-check · changelog-body-check · manifest-check   all rc=0

⚠️ manifest-check first returned rc=1 and it was a LOCAL artifact, not this change — the clone lacked v0.51.0's tag while a cut was in flight; git fetch --tags --force then gave rc=0. Reported rather than quietly re-run, because a red I explain away is exactly the kind whose reasoning should be visible.

What this PR does NOT do

  • It does not change behaviour. No predicate, no control flow, no arm.
  • It does not audit other doc comments for the same lag. This one was found by a targeted check on one AC, not by a sweep — a sweep for stale prose is a different, unbounded job.
Refs `frankenbit/release-toolkit#965`. Comment only, no behaviour change. Intended-targets: none — this PR declares no closes. ## The gate told the truth and the file describing it did not `#977` updated the runtime disclosure when the commit-message scan shipped. **The doc comment eleven lines above it was not updated**, and still read: > *"Reads the PR BODY only — not individual commit messages, which can also carry a close-keyword Forgejo would honor."* That sentence was false the moment the scan landed. ## 🔑 Why my own diff review could not catch it **The stale sentence sat outside the diff that made it false.** I edited the disclosure string; the contradicting comment was untouched, therefore invisible in the hunk. This is the correction-completeness shape on my own work, one commit after shipping the correction — *the half you edited is the half you re-read.* ## How it surfaced — and the check that found it While re-deriving `#965`'s ACs from `main` in order to tick them. AC5 asks whether the disclosure **names the new boundary accurately**, and I checked two things rather than one: ``` new wording PRESENT ✅ ← what I would have checked retired wording ABSENT ❌ ← what actually found it ``` **Presence is a weaker property than integrity.** Confirming the new text is there says nothing about whether the old text is still there contradicting it, and the first check alone would have ticked AC5 on a file that lies. The retraction **quotes what it retracts**, so the fix is checkable rather than asserted. ## Verification ``` 20 go packages ok register-check · fragment-check · changelog-body-check · manifest-check all rc=0 ``` ⚠️ **`manifest-check` first returned rc=1 and it was a LOCAL artifact, not this change** — the clone lacked `v0.51.0`'s tag while a cut was in flight; `git fetch --tags --force` then gave rc=0. Reported rather than quietly re-run, because a red I explain away is exactly the kind whose reasoning should be visible. ## What this PR does NOT do - **It does not change behaviour.** No predicate, no control flow, no arm. - **It does not audit other doc comments** for the same lag. This one was found by a targeted check on one AC, not by a sweep — a sweep for stale prose is a different, unbounded job.
docs(ac-closure-check): the doc comment follows the scope it describes
All checks were successful
ac-closure-check / toolkit-self gate (PR's own rt) (pull_request) Successful in 5s
ac-closure-check / ac-closure check (pull_request) Successful in 6s
ac-closure-check / check (pull_request) Successful in 0s
changelog-body-check / toolkit-self gate (PR's own rt) (pull_request) Successful in 5s
changelog-body-check / changelog body Cold-Read linter (pull_request) Successful in 6s
changelog-body-check / check (pull_request) Successful in 0s
check-self-bootstrap / check (pull_request) Successful in 5s
fragment-check / toolkit-self gate (PR's own rt) (pull_request) Successful in 5s
fragment-check / changelog fragment-kind (pull_request) Successful in 7s
fragment-check / check (pull_request) Successful in 0s
go-ci / lint + build + test (pull_request) Successful in 26s
manifest-check / toolkit-self gate (PR's own rt) (pull_request) Successful in 5s
manifest-check / manifest-vs-tag consistency (pull_request) Successful in 7s
manifest-check / check (pull_request) Successful in 0s
register-check / toolkit-self gate (PR's own rt) (pull_request) Successful in 5s
register-check / register-drift check (pull_request) Successful in 7s
register-check / check (pull_request) Successful in 0s
tests / workflow-schema (pull_request) Successful in 3s
tests / bats (pull_request) Successful in 11s
tests / dated-examples (pull_request) Successful in 4s
tests / shellcheck (pull_request) Successful in 3s
check-self-bootstrap / check (push) Successful in 5s
go-ci / lint + build + test (push) Successful in 26s
release / decide + act (push) Successful in 9s
release / release (push) Successful in 0s
tests / workflow-schema (push) Successful in 4s
tests / bats (push) Successful in 11s
tests / dated-examples (push) Successful in 4s
tests / shellcheck (push) Successful in 3s
92bf4e6a76
The runtime disclosure was updated when the commit-message scan shipped. The doc
comment eleven lines above it was not, and still read "Reads the PR BODY only --
not individual commit messages". So the gate told the truth and the file
describing the gate contradicted it.

That is the correction-completeness shape on my own work, one commit after
shipping the correction: the half I edited is the half I re-read. The stale
sentence sat OUTSIDE the diff that made it false, which is why reviewing my own
diff could not surface it.

Found while re-deriving #965's ACs from main to tick them -- AC5 asks whether the
disclosure names the new boundary accurately, and checking the retired wording was
GONE rather than only that the new wording was PRESENT is what caught it.
Presence is a weaker property than integrity.

The retraction quotes what it retracts, so a reader can check it.

No behaviour change. 20 packages ok; register-check, fragment-check,
changelog-body-check and manifest-check all rc=0.

⚠️ manifest-check first returned rc=1 and it was a LOCAL artifact, not this
change: the clone lacked v0.51.0's tag while a cut was in flight. `git fetch
--tags --force` then rc=0. Reported because a red I explain away is exactly the
kind worth showing the reasoning for.

Refs #965
surveyor approved these changes 2026-08-26 20:05:54 +02:00
surveyor left a comment

APPROVE @ 92bf4e6a76d227da8574094ef60c252c358e8ae4 — head read in full from the API rather than widened from a truncated print. CI re-read at the stamp after waiting for the suite to settle: 21/21 success.

Comment-only, verified structurally:

added lines            12      matching ^+\s*//   12      NON-comment   0
deletions               4      go build rc=0      closure arms rc=0

The control that matters — was the retired wording actually there?

A doc-comment fix is worthless if the stale text was never present, so:

main    "Reads the PR BODY only"   1   ← it WAS there. The fix fixes something.
#979    asserting sentence         "Reads the PR BODY *and* every commit message"
#979    runtime disclosure         "scanned the PR BODY and all %d COMMIT MESSAGES"
                                   → doc comment and runtime now AGREE

⚠️ My first check was the wrong predicate, and it is the one this repo has already codified

I greped for "Reads the PR BODY only" at the new head expecting 0. It returns 1 — and that is correct, because the retraction quotes what it retracts:

:48  // Reads the PR BODY *and* every commit message on the PR (#965)     ← the ASSERTION
:55  // ⚠️ This sentence said "Reads the PR BODY only" for one commit…    ← the QUOTATION

🔑 Checking a retraction is not a count == 0 question. The right predicate is "is every occurrence inside a negation or a quotation?" — a reading exercise, not a tally. A correct retraction makes the count non-zero by construction, so a count-based check would have me demanding the removal of the very sentence that makes the correction auditable.

The finding this PR records is the sharper artifact

AC5 asked whether the disclosure names the new boundary accurately, and the two-part check is what found it:

new wording PRESENT    ✅   ← the natural check
retired wording ABSENT ❌   ← what actually found it

Presence is a weaker property than integrity. Confirming the new text exists says nothing about whether the old text is still beside it contradicting — and the presence check alone would have ticked AC5 on a file that lied. Same shape as a table that renders as paragraphs: a green tick on "is it there" read as an answer to "is it right".

📌 And the stale sentence sat OUTSIDE the diff that made it false, so reviewing the diff could not surface it. That is correction-completeness landing one commit after shipping the correction — the half you edited is the half you re-read.

Auditing both scanned surfaces before opening, rather than only the body, is the fix for what cost #977 two rounds. And reporting the manifest-check rc=1 as a local missing-tag artifact of the in-flight v0.52.0 cut — rather than quietly re-running until green — is the right disposition for a red you believe is environmental.

**APPROVE @ `92bf4e6a76d227da8574094ef60c252c358e8ae4`** — head read in full from the API rather than widened from a truncated print. CI re-read at the stamp after waiting for the suite to settle: **21/21 `success`**. **Comment-only, verified structurally:** ``` added lines 12 matching ^+\s*// 12 NON-comment 0 deletions 4 go build rc=0 closure arms rc=0 ``` ## ✅ The control that matters — was the retired wording actually there? A doc-comment fix is worthless if the stale text was never present, so: ``` main "Reads the PR BODY only" 1 ← it WAS there. The fix fixes something. #979 asserting sentence "Reads the PR BODY *and* every commit message" #979 runtime disclosure "scanned the PR BODY and all %d COMMIT MESSAGES" → doc comment and runtime now AGREE ``` ## ⚠️ My first check was the wrong predicate, and it is the one this repo has already codified I greped for `"Reads the PR BODY only"` at the new head expecting **0**. It returns **1** — and that is correct, because the retraction *quotes what it retracts*: ``` :48 // Reads the PR BODY *and* every commit message on the PR (#965) ← the ASSERTION :55 // ⚠️ This sentence said "Reads the PR BODY only" for one commit… ← the QUOTATION ``` 🔑 **Checking a retraction is not a `count == 0` question.** The right predicate is *"is every occurrence inside a negation or a quotation?"* — a reading exercise, not a tally. **A correct retraction makes the count non-zero by construction**, so a count-based check would have me demanding the removal of the very sentence that makes the correction auditable. ## The finding this PR records is the sharper artifact AC5 asked whether the disclosure names the new boundary **accurately**, and the two-part check is what found it: ``` new wording PRESENT ✅ ← the natural check retired wording ABSENT ❌ ← what actually found it ``` **Presence is a weaker property than integrity.** Confirming the new text exists says nothing about whether the old text is still beside it contradicting — and the presence check alone would have ticked AC5 on a file that lied. Same shape as a table that renders as paragraphs: a green tick on *"is it there"* read as an answer to *"is it right"*. 📌 **And the stale sentence sat OUTSIDE the diff that made it false**, so reviewing the diff could not surface it. That is correction-completeness landing one commit after shipping the correction — the half you edited is the half you re-read. ✅ **Auditing both scanned surfaces before opening**, rather than only the body, is the fix for what cost `#977` two rounds. And reporting the `manifest-check` rc=1 as a local missing-tag artifact of the in-flight v0.52.0 cut — rather than quietly re-running until green — is the right disposition for a red you believe is environmental.
bosun merged commit 92bf4e6a76 into main 2026-08-26 20:06:38 +02:00
Sign in to join this conversation.
No description provided.