fix(ac-closure): explain stale issue status refresh #1245
No reviewers
Labels
No labels
bump
major
bump
minor
bump
patch
kind/bug
kind/chore
kind/docs
kind/feature
priority/critical
priority/high
priority/low
priority/medium
size/L
size/M
size/S
size/XL
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
frankenbit/release-toolkit!1245
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "i/1211-ac-closure-stale"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
ac-closure-checkgrades acceptance-criteria boxes on referenced issues but is triggered bypull_requestevents. Ticking an issue after a refusal therefore leaves the posted PR status stale. This changes the refusal diagnostic to explain the cross-object trigger and tell the author to touch the PR (edit its body or push a follow-up) after fixing the issue.The reusable and toolkit-self wrapper comments plus adopter integration docs record the same contract. The gate remains fail-closed; this is a diagnostic remedy, not a re-fire on every referenced issue.
Refs #1211
Controls
runACClosureCheckreturns the normal exit-1 refusal and the output names the graded issue, pull-request trigger, stale-status behavior, and PR-touch remedy.grades issue/touch this PRdiagnostics; the existing clean-target control remains green.Full checks:
go test ./...,go vet ./...,go build ./...,bats tests/workflows.bats(108/108),go run ./cmd/rt register-check,go run ./cmd/rt fragment-check changelog.d, andgit diff --check.Related scope
#1217 is related state-moved/gate-noticed work, but remains a separate tracker: it is review-row lifecycle (
REQUEST_CHANGESversus approval dismissal), while this change is the issue-edit versus pull-request-trigger seam. They have different code paths, owners, and controls.APPROVE — reviewed at
9173ffff, CI terminal at that head with 0 non-success. Every claim below is reproduced at that SHA rather than read off the diff.The change does what it says
The refusal now names the cross-object seam. I ran the two mutations that matter and they redden different arms, which is what makes this pinned rather than merely covered:
dirty targetcase andStaleIssueRemedyDisclosedStaleIssueRemedyDisclosedonly — its negative halfThe second is the one I'd have expected to be missing. The arm asserts the remedy is absent from a clean re-run, so the message cannot leak into a pass and become decoration. Good.
Checks
go test ./...,go vet ./...,gofmt -lclean at this head..forgejoand.giteascope blocks are byte-identical (diffed, not eyeballed) — the twin is genuinely regenerated.ac_closure_check.go:94really does callPRCommitMessagesand union its targets with the body's.One finding, non-blocking, and it is about ORDER rather than about this diff
This PR ships documentation that is not yet true, because the reader behind it lands in a different PR.
The scope text now says, unconditionally, "Reads the PR BODY and every commit message" — in
docs/integration.md, both reusables, and the doc comment. At this head,PRCommitMessagesis still the bare unpaginated call:So "every commit message" is true only up to page one until #1240 lands, and #1240 is still
state=open merged=false.⚠️ Latent, not observed — the largest PR in this repo has 4 commits, so nothing crosses a page boundary today, and I found nothing that upgrades that. I am not asking for a change here: #1240 is approved and this is the correct end state once it merges.
🔑 Why I am naming it anyway: that sentence is a supporting clause. It licenses no action, so nobody cites it, deletes on it or pushes on it — which is exactly the class that rides through every review it passes. The two PRs are now coupled and neither body says so. Whichever lands second closes the gap; if #1245 lands first, the docs are ahead of the code for that window.
📌 Also worth a note for whoever merges: this PR removes the ⚠️ block in
ac_closure_check.gothat recorded the previous instance of this same shape — the doc comment that still said "Reads the PR BODY only" for a commit after the commit scan shipped. Deleting the record of a stale-doc incident inside a PR about keeping docs current is defensible (the history has it), but it is the second occurrence of that shape on this one file and the note was the only in-tree marker of the first.No duplicate review request filed; not merging.