Skip to content

feat(issues): give docs/outstanding-issues.md a writer, not just a gate - #1524

Merged
BigSimmo merged 7 commits into
mainfrom
claude/issues-writer-cli
Jul 31, 2026
Merged

feat(issues): give docs/outstanding-issues.md a writer, not just a gate#1524
BigSimmo merged 7 commits into
mainfrom
claude/issues-writer-cli

Conversation

@BigSimmo

@BigSimmoBigSimmo commented Jul 31, 2026

Copy link
Copy Markdown
Owner

Summary

  • Add opt-in, privacy-first server-side Sentry error tracking that is inert without SENTRY_DSN and scrubs request, user, body, breadcrumb, and clinical content before export.
  • Surface conservative, normalized source-governance metadata in the RAG prompt so generation can see provenance state without inventing adverse unverified status for empty, index-only, or partial-sibling documents.metadata.
  • Document the privacy envelope, operator approval checklist, and rollback path in docs/error-tracking.md.

RAG impact: no retrieval behaviour change — prompt presentation only adds conservative normalized source-governance metadata; retrieval, ranking, and source selection are unchanged.

Verification

  • npm run verify:pr-local
  • Focused Vitest for tests/error-tracking.test.ts, tests/rag-source-governance-prompt.test.ts, and tests/source-metadata.test.ts
  • npm run eval:rag:offline — 36/36 golden retrieval cases
  • npm run check:production-readiness:ci returned READY (offline; expected missing-env warnings)
  • npm run build succeeded for production instrumentation wiring
  • Merged origin/main and resolved Codex Cloud git-remote helper conflicts; git merge-tree vs origin/main is clean
  • UI verification not run: no UI, routing, styling, or browser-behavior changes
  • Live answer-generation quality evaluation not run — OpenAI/provider interaction requires explicit owner approval

Risk and rollout

  • Risk: medium; optional Sentry path is disabled unless configured, but prompt wording changes answer-generation context and should land only with owner acceptance of offline evidence or an approved live answer-quality check.
  • Rollback: revert the squash-merge commit on main, remove SENTRY_DSN and restart services if observability was enabled, and confirm prompts no longer emit the Source governance line.
  • Provider or production effects: None unless an operator explicitly sets SENTRY_DSN; no browser DSN, tracing, or source-map upload is configured.

Clinical Governance Preflight

  • Source-backed claims still require linked source verification before clinical use
  • No patient-identifiable document workflow was introduced or expanded without explicit governance approval
  • Supabase target remains Clinical KB Database (sjrfecxgysukkwxsowpy)
  • Service-role keys and private document access remain server-only
  • Demo/synthetic content remains clearly separated from real clinical sources
  • Source metadata, review status, and outdated/unknown-source behavior remain conservative
  • Deployment classification/TGA SaMD impact was checked when clinical decision-support behavior changed

Notes

  • Empty/{}/index-only governance metadata remains unrecorded in prompts; partial sibling fields use neutral unknown rather than inventing adverse unverified; explicit stored clinical_validation_status: "unverified" from upload is preserved.
  • Optional Sentry init failures are swallowed so observability cannot block production boot.
  • Merge remains gated on approved live answer-quality verification or an explicit owner decision to accept the offline-only evidence.

docs/branch-review-ledger.md has had a writer since it was introduced and
hand-authoring a row there is forbidden. This file had a gate but no writer, so
every mutation was hand-authored — and the 2026-07-30/31 session produced
exactly the failures that predicts, none of them judgement calls: rows appended
into the archive table because the author anchored on an id that had since been
archived, an unescaped pipe splitting a row into extra cells, and ids read off
the marker by eye.
scripts/outstanding-issues.mjs adds add/done/update. It imports the gate's
parser rather than re-deriving table bounds or widths, so the rules live in one
place, and it re-runs the gate against its own output before writing — a
refusal here is the same refusal CI would give, minus the round trip.
Wired as issues:add / issues:done / issues:update, with the writer's self-test
chained into check:outstanding-issues so CI exercises it, mirroring
check:branch-review-ledger. The issues skill now points at the CLI, since a tool
nobody is told to use changes nothing.
It deliberately does NOT fix id collisions between concurrent branches:
allocation is still read-modify-write against the marker. #159, added with the
writer itself, records that fix — collision-free ids, after which a union merge
driver becomes safe to reinstate.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@supabase

supabaseBot commented Jul 31, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project sjrfecxgysukkwxsowpy because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@coderabbitai

coderabbitaiBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in:20 minutes

Your organization has reached its usage spending cap. Adjust your spending cap in the billing tab.

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: f0571b74-86b1-427d-ad96-24e9f0d96dc4

📥 Commits

Reviewing files that changed from the base of the PR and between d5cd804 and fb807b1.

📒 Files selected for processing (7)
  • .claude/skills/issues/SKILL.md
  • docs/branch-review-ledger.md
  • docs/outstanding-issues.md
  • docs/scripts-index.md
  • package.json
  • scripts/outstanding-issues.mjs
  • tests/outstanding-issues-writer.test.ts

Comment @coderabbitai help to get the list of available commands.

@BigSimmo

Copy link
Copy Markdown
OwnerAuthor

@cursoragent Work this open PR (confirm number + GitHub head first). Start from
origin/ matching that head; preserve unrelated local WIP.
Do not merge, force-push, rebase, or arm auto-merge. No provider-backed
gates without approval. If you can’t push or resolve threads: diagnose +
comment only.

Goal: review + Bugbot the tip, fix actionable issues with smallest changes,
clear merge/required-CI/thread blockers, push fixes, post one PR summary.
Stay light — no full local verify:* / Playwright / broad suites unless
needed to prove one concrete fix. Don’t regenerate large assets unless required.

  1. Snapshot tip, behind/ahead, mergeable, merge-tree (real conflict vs
    behind-but-clean), required checks on that tip, unresolved actionable
    threads. Missing checks while dirty ≠ green. If the tip moves mid-work,
    re-snapshot.
    npm run ledger:lookup -- <branch> --scope "PR #<n> review+bugbot+fix".
    If already reviewed at this HEAD/scope and still clean with required checks
    green and no new actionable threads: summarize, comment, stop.

  2. Unblock once: real conflict → merge origin/main (for ledger/issues churn,
    prefer main’s queues, keep this PR’s notes); behind-but-clean → sync once
    (wait if required CI is in flight); else leave. No sync thrash.
    If auto-merge is already armed, push only for a real blocker.

  3. Review + Bugbot the delta vs base. High-confidence only (correctness,
    security, privacy, auth, data loss, migrations/RLS, clinical/RAG/source,
    prod reliability, user-facing). Separate PR-introduced defects from
    pre-existing re-emitted data. For generated assets, review generator/
    contracts/aliases/cache — not every generated line. If RAG/governance
    surfaces are touched, note/fix PR body only when policy text is wrong
    or missing. Ignore bot summary/rate-limit noise.

  4. Fix P0/P1 always; fix clear scoped P2; otherwise short disposition reply
    then resolve. Fix required-check failures on this tip only (ignore advisory).
    Prove with the smallest targeted check only. No broad refactors.

  5. Format + commit before push. Push only this PR’s fix commits. Append ledger
    for the final GitHub head + scope above (--supersede on a requested fresh
    same-HEAD pass). Never push a ledger-only tip.

  6. Post one concise top-level PR comment: tip SHA, sync, fixed vs dispositioned,
    required CI status, residual risks. Leave merge to me. Inline comments only
    for remaining open P0/P1 needing a human decision.

Stop when merge-tree clean, no actionable threads left, and required checks are
green or clearly in progress on the current tip.

@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

PR #1524 tip is now 83dec1f5 — merge conflict cleared, review done, CI running.

Snapshot → unblock

Review + fix

  • One clear P2: skill/writer cited #154 for id collisions (wrong) → #156 / #168.
  • No other high-confidence writer defects; residual risk remains concurrent RMW ids.

Status

  • Pushed 83dec1f5; merge-tree clean; GitHub MERGEABLE; required CI in progress.
  • Ledger row recorded locally for that tip (not pushed — avoids a ledger-only tip).
  • Summary posted on the PR; merge left to you.
Open in WebOpen in Cursor

cursoragentand others added 2 commits July 31, 2026 08:16
Resolve real conflicts in docs/outstanding-issues.md and docs/scripts-index.md:
keep main's open queue, renumber this PR's collision-free-ids note to #168
(main already owned #159), bump next-id to 169, keep package.json script
count at 212. Correct the writer/skill cross-ref from #154 to #156/#168.
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

PR #1524 babysit summary

Tip:83dec1f5a36d577c87ee9a5382ef8431d197d93d (was 92be04d6)
Sync: merged origin/main once — real conflicts in docs/outstanding-issues.md + docs/scripts-index.md (not behind-but-clean). merge-tree clean; GitHub MERGEABLE.
Threads: none actionable (Codex/CodeRabbit rate-limit noise only).

Fixed

  • Conflict resolution: kept main’s open queue (#159 duplicated-test-lists, #162#167); renumbered this PR’s collision-free-ids note #159#168, next-id=169; scripts-index count stays 212.
  • P2 citation drift: skill + writer header said “see #154” for id collisions; #154 is land-verification — corrected to #156 / #168.

Review / Bugbot (delta vs base)

No further high-confidence P0–P2 in the writer. Covered: open-table append, pipe escape, done move+reshape, double-archive refuse, gate re-check before write. Residual risk: concurrent RMW id allocation (#156/#168) — intentionally out of scope.

Checks

  • Local: check:outstanding-issues pass · writer --self-test pass · vitest tests/outstanding-issues-writer.test.ts8/8 · format clean
  • Hosted: CI / Static PR / Safety / coverage / build in progress on this tip (PR mergeability already green). No provider-backed gates.
  • Ledger row recorded locally for 83dec1f5 / scope PR #1524 review+bugbot+fix (not pushed — avoids a ledger-only tip).

Merge left to you.

@github-actions

github-actionsBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

CI triage

CI failed on this PR. Automated classification of the 2 failed job(s):

  • Static PR checksneeds investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.
  • PR requiredneeds investigation: inspect the failing step and uploaded diagnostics; rerun only after classifying the cause.

Compared with main CI run #7550 (cancelled).

Classification is evidence routing, not permission to ignore a failure. Exact quarantined Playwright identities remain governed by the flake ledger.

Static PR docs:check-inventory expected 197 script files (this PR adds
outstanding-issues.mjs); the merge resolution left the stale 196 count.
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

CI fix

Root cause: both red checks were the same failure — Static PR checksdocs:check-inventory (PR required is the aggregate).

Merge resolution left docs/scripts-index.md at 196 script files; this PR adds scripts/outstanding-issues.mjs, so inventory expects 197.

Fix:16050576 — refreshed the count via npm run docs:update. Local docs:check-inventory now passes. CI re-running on the new tip.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@BigSimmo

Copy link
Copy Markdown
OwnerAuthor

@cursoragent please resolve all issues and failing CI and merge conflict

@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

PR #1524 is already merged — nothing left to fix.

Squash on main: b3d60241 (feat(issues): … (#1524)). Tip a8af9291 vs squash is an empty diff, so nothing was orphaned.

What had been blocking (all fixed before merge):

  • Merge conflicts → synced
  • docs:check-inventory (196 → 197) → fixed
  • docs:check-links (`docs/issues/`) → fixed
  • Required CI → green (Static PR, PR required)

Stale failure notes for older tip 7b8ed076 are obsolete.

Open in WebOpen in Cursor

#168 proposed a future per-row directory as `docs/issues/`; the trailing
slash made check-docs-links require that path to exist. Drop the slash so
it is treated as an extensionless directory mention, not a missing file.
Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

CI follow-up

Two real Static PR failures (PR required is the aggregate):

  1. docs:check-inventory — merge left scripts-index at 196 files; writer adds a file → expected 197. Fixed in 16050576.
  2. docs:check-links#168 cited future path `docs/issues/`; trailing slash made the checker require it. Fixed in fb807b11 (`docs/issues`).

Also synced once for behind-but-clean (GitHub DIRTY while merge-tree clean). Semgrep ingestion gate earlier failed on Docker Hub timeout — infra flake, not this diff.

Tip fb807b11. Local: docs:check-inventory + docs:check-links + check:outstanding-issues green. CI re-running.

Co-authored-by: BigSimmo <BigSimmo@users.noreply.github.com>
@BigSimmo
BigSimmo enabled auto-merge (squash) July 31, 2026 08:54
@BigSimmo
BigSimmo merged commit b3d6024 into mainJul 31, 2026
24 checks passed
@BigSimmo
BigSimmo deleted the claude/issues-writer-cli branch July 31, 2026 08:57
@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

CI fixed — green

Tip:a8af9291

Both original reds were Static PR checks (with PR required as the aggregate):

FailureCauseFix
docs:check-inventoryscripts-index still said 196 files; writer adds one → 19716050576
docs:check-links#168 cited future `docs/issues/`fb807b11 (drop trailing slash)

Also synced origin/main twice for behind-but-clean GitHub DIRTY states so pull_request CI could run.

Hosted:Static PR checks pass · PR required pass · mergeability pass. Merge left to you.

@cursor

cursorBot commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Status: already resolved and merged

PR #1524 is MERGED (mergedAt 2026-07-31T08:57:39Z).

  • Squash on main: b3d602415e4f723318e33278a5567416d3863316
  • Final tip before merge: a8af9291
  • Required CI was green (Static PR checks, PR required, mergeability)
  • Content verified on main: writer script, issues:add|done|update, scripts-index 197, #168 link cite without trailing slash
  • git diff squash vs tip: empty (nothing orphaned)

Stale CI annotations for older tip 7b8ed076 (docs links / Docker Hub flake) are superseded. Nothing left to fix or sync on this PR.

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@BigSimmo@cursoragent