fix(sealed): waivers must name the full commit sha (GST-268)

Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
garrytanandcapy-ai[bot] committed 2026-10-30 14:04:53 +00:00
1 parent ce3a093a64
commit a210bd3644
6 files changed
+105 -16

No files matched your search

+5 -1
View File
@@ -840,7 +840,11 @@ gstack-pregate sealed [--range <a..b>] [--remote origin] [--base <branch>] [--js
`git ls-remote <remote> <ref>`. A malformed or
unreadable policy refuses. Waivers come only from the base branch's
`.gstack/sealed-allow.tsv` (`rule<TAB>path<TAB>sha<TAB>reason`) and are
listed on every push.
listed on every push. A waiver counts only when `sha` is the finding's full
commit sha (40 hex characters, 64 in a SHA-256 repository); a shortened or
mistyped one is ignored, so the finding still refuses, and stderr names it
(`ignored waiver <rule> <path> sha <value>`) with the full commit to write.
`--json` lists them as `ignoredWaivers`.
- **Visibility.** `sealed.visibility` from the base branch, else a cache under
the state root (`sealed-visibility.json`: a `public` answer for 24 hours, a
`private` one for 1 hour before it may turn a refusal into a warning), else
+2 -1
View File
@@ -3825,7 +3825,8 @@ and counts) can be exempted from the path rules with a `sealed.allow_paths`
glob in the base branch's `.gstack/pregate.json`; the text rules still read it
([docs/pregate.md#sealed](pregate.md#sealed)). A reviewed false positive gets
one line in the base branch's
`.gstack/sealed-allow.tsv`: `rule<TAB>path<TAB>sha<TAB>reason`. A private
`.gstack/sealed-allow.tsv`: `rule<TAB>path<TAB>sha<TAB>reason`, where `sha` is
the full commit sha (a shortened one is ignored and named on stderr). A private
destination sets `"visibility": "private"` under `sealed` in the base branch's
`.gstack/pregate.json`. Capy's pull-request tool may not run local hooks, so
run `gstack-pregate sealed` yourself before any push or PR creation.