feat(dev): surface QA findings on direct handoff; gate just validate #35

Merged
erik merged 1 commit from feat/dev-qa-handoff into main 2026-06-25 01:06:40 +00:00
Member

Why

dropbear#9 (telemetry run cedcb912) exposed two failures in the agent loop:

  1. Blind validation. agent-dev claimed an already-implemented branch, made zero edits, yet still ran just check + just validate — ~58k tokens to gate a no-op. It has also run just validate after a ./wiki/-only update.
  2. QA feedback silently dropped. QA found a real bug and handed the issue directly back to agent-dev (the path meant to avoid a PM round-trip), but fjx dev next only injects the pm:brief:dev comment — which was stale. Dev followed the stale brief, never read the agent-qa ledger, re-validated, and re-reported "done."

What

  • src/commands/dev.tsrunDevNext now reads the agent-qa:ledger and, when its verdict is fail/concerns, surfaces it as a ## QA Findings — address before re-submitting section above ## Next Steps. Gated on verdict via the existing statusFromLedger parser so a prior pass doesn't re-surface across cycles (the ledger is upserted in place and persists). This makes the existing qa.md direct-return path effective with no agent-pm translation tick.
  • src/prompts/dev-bootstrap.mdjust validate becomes a final, change-gated gate (skip when the cycle changed no code, or only docs/./wiki//ledger/findings); and dev is told to treat a surfaced ## QA Findings section as the spec for the cycle, citing fixes rather than re-reporting prior work.
  • Testssrc/dev.test.ts adds coverage: surfaces on fail, omits on pass, omits when no QA ledger.

Also bundles pre-existing in-progress pm changes (plan.ts, pm.ts, pm-bootstrap.md) and tracked-artifact updates per request.

Verification

  • deno test src/dev.test.ts → 11 passed (3 new).
  • just check and just validate → clean.

🤖 Generated with Claude Code

## Why dropbear#9 (telemetry run `cedcb912`) exposed two failures in the agent loop: 1. **Blind validation.** agent-dev claimed an already-implemented branch, made zero edits, yet still ran `just check` + `just validate` — ~58k tokens to gate a no-op. It has also run `just validate` after a `./wiki/`-only update. 2. **QA feedback silently dropped.** QA found a real bug and handed the issue **directly back to agent-dev** (the path meant to avoid a PM round-trip), but `fjx dev next` only injects the `pm:brief:dev` comment — which was stale. Dev followed the stale brief, never read the agent-qa ledger, re-validated, and re-reported "done." ## What - **`src/commands/dev.ts`** — `runDevNext` now reads the `agent-qa:ledger` and, when its verdict is `fail`/`concerns`, surfaces it as a `## QA Findings — address before re-submitting` section above `## Next Steps`. Gated on verdict via the existing `statusFromLedger` parser so a prior `pass` doesn't re-surface across cycles (the ledger is upserted in place and persists). This makes the existing `qa.md` direct-return path effective with no agent-pm translation tick. - **`src/prompts/dev-bootstrap.md`** — `just validate` becomes a final, change-gated gate (skip when the cycle changed no code, or only docs/`./wiki/`/ledger/findings); and dev is told to treat a surfaced `## QA Findings` section as the spec for the cycle, citing fixes rather than re-reporting prior work. - **Tests** — `src/dev.test.ts` adds coverage: surfaces on fail, omits on pass, omits when no QA ledger. Also bundles pre-existing in-progress pm changes (`plan.ts`, `pm.ts`, `pm-bootstrap.md`) and tracked-artifact updates per request. ## Verification - `deno test src/dev.test.ts` → 11 passed (3 new). - `just check` and `just validate` → clean. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
feat(dev): surface QA findings on direct handoff; gate just validate
All checks were successful
Validate / validate (pull_request) Successful in 36s
d50cc6a8ac
When QA returns a fail/concerns issue directly to agent-dev (the no-PM-round-trip path), `fjx dev next` previously injected only the `pm:brief:dev` comment — which is stale on that path — so dev never saw the findings and re-reported the prior work as done (observed on dropbear#9, telemetry cedcb912). `runDevNext` now also reads the `agent-qa:ledger` and, when its verdict is `fail`/`concerns`, surfaces it as a `## QA Findings` section above Next Steps. Gated on verdict via the existing `statusFromLedger` parser so a prior `pass` doesn't re-surface across cycles.

Prompt edits in dev-bootstrap.md: make `just validate` a final, change-gated gate (skip when the cycle changed no code, or only docs/wiki/ledger/findings) instead of a reflexive probe, and tell dev to treat a surfaced `## QA Findings` section as the spec for the cycle.

Also bundles in-progress pm changes (plan.ts, pm.ts, pm-bootstrap.md) and assorted tracked-artifact updates.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
erik merged commit 80e07df446 into main 2026-06-25 01:06:40 +00:00
erik deleted branch feat/dev-qa-handoff 2026-06-25 01:06:40 +00:00
Sign in to join this conversation.
No description provided.