Skip to content

ADR-0068 and the risk-paths spec: label PRs that touch high-risk paths - #190

Merged
bketelsen merged 2 commits into
mainfrom
lucilla/adr-0068-risk-paths
Nov 4, 2026
Merged

bketelsen merged 2 commits into
mainfrom
lucilla/adr-0068-risk-paths

Conversation

@frostyard-machines

@frostyard-machines frostyard-machines commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds ADR-0068 and the spec docs/specs/risk-paths.md (plan T801, task t3, section "Gap 3: risk paths").

  • Each repository lists its high-risk paths in .github/risk-paths.json (schema_version 1, paths[].glob, paths[].why, deny-by-default validation).
  • A core reusable workflow, called on pull_request_target, reads the list at the base SHA, reads the changed files from the API, checks out no PR head code, and adds risk:high. It never removes the label and never creates it.
  • Label rule: a non-owner PR waits for the owner's review comment before ready-for-human; an owner PR has the label as its gate, and Brian reads every risk:high PR.
  • Back-links: ADR-0019 and ADR-0020 (link-only, ADR-0033), docs/design/quality-loop.md (new "Flag risk paths" station), docs/README.md index.

Docs only. The validator, matcher, reusable workflow, core's own list and caller, and the repository-surfaces entry come in task t4, with tests.

ADR number: 0068 was free on main (2d5dc14) and in every open PR when this PR opened.

Decision trail (not in the ADR, per ADR-0051)

  • T801a (Brian, 2026-11-03): core reusable workflow, not the Desk sweep.
  • T801b (Brian, 2026-11-03): owner-authored risk:high PRs: label only; Brian reads.
  • Murbella's consult (f1) set the 3 conditions: pull_request_target, list from the base SHA, no head checkout; job permissions contents: read + pull-requests: write. Sheeana's consult (f2) proposed a Desk part; T801a left it out.

Risk tier

Risk tier: 1 — docs only (ADR, spec, design doc, index). No workflow, script or authority file changes.

Docs housekeeping

  • New docs started from their category's TEMPLATE.md
  • Every new doc indexed in docs/README.md
  • Cross-links added in both directions (ADR-0068 ↔ spec ↔ quality-loop; ADR-0019 and ADR-0020 back-links)
  • New significant decision recorded as an ADR first, in this PR
  • New/edited ADRs are fact-only — no narration of who asked or who was consulted
  • Conformance aliases (ADR-0029) untouched

Verification

  • node scripts/check-docs.mjs green: checked: 91 docs, 914 links, 10 symlinks
  • make verify green: # pass 74, # fail 0
  • Scaffold not changed
  • Workflows not changed

Revert test: exempt (docs only, no behavior). The docs gate still proves the new links, in a scratch worktree from the PR head (git worktree add --detach … HEAD):

  • index line of specs/risk-paths.md removed → FAIL index: docs/specs/risk-paths.md has no line in docs/README.md, exit 1;
  • ADR-0068 link in quality-loop.md broken → FAIL link: docs/design/quality-loop.md -> ../adr/0068-missing.md does not resolve, exit 1;
  • restored → exit 0. Worktree removed.

Coder: github-copilot/mai-code-2-flash (subagent), reviewed and edited by Lucilla.

Cross-review

Reviewer openai/gpt-6.1-sol; coder github-copilot/mai-code-2-flash (author edits on Claude). Base 2d5dc14.

  • Initial review at 4c8d2a6: Not ready, 3 blocking findings, 1 low. All 4 accepted and fixed in 7696d60:
    1. A base-branch change sends edited, not synchronize, so a PR could avoid the label by retargeting. The caller now also runs on edited and reads the list at the new base SHA. (This adds edited to the plan's types opened, synchronize, reopened.)
    2. Bare ** contradicted the root-only rule for globs with no /. It is now the exception and matches every path; added examples.
    3. ADR-0019 now links the spec too (link-only, ADR-0033).
    4. The why validation text now matches the field table.
  • Re-review 1 of 3 at 7696d60: Ready, Blocking: none.

@frostyard-machines frostyard-machines added the ready-for-human Reviewed, CI green: ready for Brian to review and merge label Nov 4, 2026
@bketelsen
bketelsen merged commit 20fd8a3 into main Nov 4, 2026
3 checks passed
@bketelsen
bketelsen deleted the lucilla/adr-0068-risk-paths branch November 4, 2026 14:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-human Reviewed, CI green: ready for Brian to review and merge

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants