Repository navigation
Stop mistaking ordinary text for Capy ids and check every part of a public PR body (GST-4105) - #4872
Merged
Merged
Conversation
…ublic PR body (GST-4105) Text like SHA-256:abc, PR-12:fix or test/jam_fix.ts no longer reads as a Capy id on public repositories, while every real id and relay ref is still caught. Writing the shipping record, moving it to a new commit and marking an abandoned run now also check the earlier-runs block and abandon reasons for home paths and ids. Marking an abandoned run touches only an open PR that records the run, on the repository the branch pushes to. The merge check accepts a private repository's pre-redaction gate disposition line again, and a hand-edited runs entry with a non-text run no longer crashes the round count. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
|
😎 This pull request was merged. |
Review-Finding: p1/specialist-batched#1 reader=security Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…ruling line Review-Finding: p2/outside-voice#1 reader=outside-voice Review-Finding: p2/outside-voice#2 reader=outside-voice Review-Finding: p2/outside-voice#3 reader=outside-voice Review-Finding: p2/outside-voice#4 reader=outside-voice Review-Finding: p2/adversarial-native#1 reader=adversarial-native Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Merged
capy-ai Bot
added a commit
that referenced
this pull request
Nov 28, 2026
- Dependency and CI action updates, each checked against its publisher. (#4873) - The PR body check no longer loses the closing Agent notes section when the text quotes a `<!--` comment opener in inline code or a code block, (#4874) - `/gstack-ship` stops mistaking ordinary text for Capy ids, and checks every part of a public PR body it posts. (#4872) - `/gstack-ship` no longer puts home folder paths or Capy thread and message ids into PR bodies on public repositories. (#4868) - `/gstack-ship` no longer stops or blocks because of time and tokens that belong to something else. (#4877) - /gstack-ship keeps its token cap and clock when its budget start reruns mid-run. (#4882) - `/gstack-ship` stops reopening findings that were already settled, and a missing run folder no longer costs a docs-audit attempt. (#4875) - `/gstack-ship` closes five gaps in how it records reviews, and `--for gstack-ship` now installs the ship skill on Capy. (#4867) - The stable release no longer skips a fully tested commit because a report-only workflow failed on it. (#4865) - A test that copies its own `bun` binary no longer stops `/gstack-ship` with a fetch violation. (#4876) - The secrets check no longer reports an 11-digit GitHub Actions run id as a phone number when code names it with a camelCase run identifier (#4881) - `/review` now always runs its Codex second-model review when Codex is ready, and runs the Red Team on diffs over 200 lines. (#4870) - The factory scorecard's red-train rate now counts each train (one batch of PRs tested together) once per report, by its branch, so re-testing the same batch inside the report's window no longer moves the rate. (#4880) - The secrets check catches more Google API keys in encoded text, reads each JavaScript and TypeScript declaration under its own name, reports a provider key once, and stops matching look-alike values against your environment's secrets. (#4871) - The secrets check now catches keys in JavaScript, TypeScript and Go declarations, and stops flagging JSON key paths, run folders and base64 noise. (#4869) - The paid shared-code review test no longer fails a correct review that printed a caller file with `cat -A`. (#4878) - The weekly benchmark line in the stable release plan now also strips C1 control characters and the Unicode line and paragraph separators (U+2028, U+2029) from record text, (#4866) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On public repositories,
/gstack-shipno longer refuses or rewrites ordinary text such asSHA-256:abcortest/jam_fix.tsas if it were a Capy id, and it now checks every part of the PR body it posts.Why: these are the follow-ups #4868 left open. It made public PR bodies safe but caught too much and left a few corners unchecked.
Nothing to do: private repositories keep working with PR bodies written before #4868.
What changed
After #4868, a public PR body that mentioned a hash (
SHA-256:abc), an encoding (UTF-8:x), an issue ref (PR-12:fix) or a file such astest/jam_fix.tswas refused or had that text swapped for "a private message". Now only real Capy ids count:jam_,icm_andiev_ids, and relay refs whose message part is one of those ids, a date or time, or epoch seconds. Every earlier catch stays in the tests, beside new tests for the look-alikes. A relayed ruling still reads "relayed from a private message" on a public repository, whatever its ref looks like, and a ruling whose reason merely says "relayed from" in its own words is no longer refused.Writing the shipping record, moving it to a new commit and marking an abandoned run now also check the earlier-runs block they post, abandon reasons included, so a home folder path or Capy id there can't publish on a public repository.
Marking an abandoned run on a PR now touches only an open PR whose body records that run. It compares the PR's head with the repository the branch pushes to (its
pushRemoteorremote.pushDefault, elseorigin, at that remote's push URL), so contributors whoseoriginis upstream can use it.The merge check accepts a private repository's
Gate disposition:line written before ids were redacted again; public repositories still need the redacted line. A hand-edited earlier-runs entry whose run isn't text no longer crashes the review-round count, and a repeated abandon mark is placed only once. docs/troubleshooting.md documents the new refusals.Why
Keeping private ids and home folders out of public PR bodies only works if the check is accurate. Over-catching blocked real work, and the unchecked corners could still let a path through.
Blast radius
The changes touch the shipping-record tool (writing a record, moving it to a new commit, marking an abandoned run), the Capy-id pattern its callers share, the merge check's gate-disposition line match and the review-round counter. Each new refusal fails closed and writes nothing. Private repositories keep every earlier behavior, and the new public-repo test file covers each path: 32 cases pass, and 16 new ones failed on the code before each fix.
Pre-Landing Review
Three full reviews ran, the last one read-only on the final code. The first found one informational gap in timestamp matching, which is fixed. A second-model review then found four real bugs in this PR's new code, fixed before the final review: abandon checked a different runs block from the one it edits, an epoch ref followed by a period slipped through, the fork check read the fetch URL instead of the push URL, and the relay check read the ruling's reason. The final review found no blockers.
Review notes
Below the blocking floor (advisory, informational, test-gap or wording items); recorded here and not fixed in this PR.
sf-df554b2cbd19security finding, details recorded privatelysf-d0ea13941c40security finding, details recorded privatelysf-4b9448b0e63dsecurity finding, details recorded privatelysf-e722bb3f56d9security finding, details recorded privatelysf-f551079373c5security finding, details recorded privatelyDocumentation
Status: current. The docs already describe the branch's behavior, so nothing was edited.
Scope: 7 committed files from bbe63d1 to c177903 (the shipping-record tool, lib/ruled-notes.ts, lib/gate-dispositions.ts, lib/pr-review-history.ts, a test, a changelog fragment and docs/troubleshooting.md), plus a repository-wide search of the authored docs and templates for the changed contracts (Capy id matching, relayed Ruled note refs, the runs-block leak refusals and abandon's PR checks).
Documentation health
relayed from a private message.Coverage debt: reference and how-to coverage live in docs/troubleshooting.md. There is no explanation-level doc for how abandon picks the push remote (
pushRemote, thenremote.pushDefault, thenorigin); this is minor debt. Diagram drift: none, since no diagram covers these modules.Tests
bun test test/ship-receipt-public-safe.test.ts: 32 pass, 0 fail (16 new cases each failed before its fix: 12 on main bbe63d1, 4 on 822c4ec)bun test test/module-size-ratchet.test.ts test/troubleshooting-anchors.test.ts: passbun run typecheckclean;bun run typecheck:test: no new diagnosticsAgent notes
Refs GST-4105. Follow-up to #4868.
Approvals
Approved: yes (record r-ec7300b481c5). The full approval record stays private.
Plan: exempt: bug fix follow-up to #4868 (R4, R65)
Plan check: exempt bug fix
REVIEW_LOOP: passes=3 blocking_found=4 deferred=0 noted=9 fixed=6 scope=frozen ledgers_read=4 dispatches=9
Gate edits: none detected (4 listed, 2 read; patterns: RH-1,RH-3,RH-4,RH-12,RH-13,RH-14,RH-15,RH-16; unlisted idioms: none)