Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions .adv/archive/2026-07-26-fixReviewerEvidence/ARCHIVE_SUMMARY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Archive: Fix reviewer evidence verification

**Change ID:** fixReviewerEvidence
**Archived:** 2026-07-26T17:57:14.971Z
**Created:** 2026-07-25T20:13:01.723Z

## Tasks Completed

- ✅ Add rq-reviewerEvidenceAuthority01 to advance-workflow spec
> Task checkpoint completed
- ✅ Policy-gate verificationWarnings emitter (TDD red→green)
> Task checkpoint completed
- ✅ gate-readiness regression tests + full check sweep
> Task checkpoint completed

## Specs Modified

83 changes: 83 additions & 0 deletions .adv/archive/2026-07-26-fixReviewerEvidence/BRIEFING_DIGEST.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# Archive Briefing Digest

**Change ID:** fixReviewerEvidence
**Title:** Fix reviewer evidence verification
**Status:** archived
**Generated:** 2026-07-26T17:57:15.018Z

## Identity Anchors

- CHANGE
- STATUS
- TERMINAL_GATE_SUMMARY
- Origin: discovery

## Archive Digest

**Status:** archived

| Gate | Status |
| --- | --- |
| proposal | done |
| discovery | done |
| design | done |
| planning | done |
| execution | done |
| acceptance | done |
| release | pending |

## Epic Context

No Epic membership

## Durable Facts

Showing 21 of 21 durable facts.

- **[archive_only_evidence]** decisions: Chose tags workflow, verification, evidence, structural, review for rq-reviewerEvidenceAuthority01 — Mirrors neighboring rq-verificationEvidence01 tags and adds review to capture the requirement's subject.
- **[archive_only_evidence]** verification: bin/oc-test targeted -- src/adv-autonomy-quality-assets.test.ts (1) — RED: 7 new rq-reviewerEvidenceAuthority01 assertions fail (requirement absent); 35 existing tests pass.
- **[archive_only_evidence]** verification: bin/oc-test targeted -- src/adv-autonomy-quality-assets.test.ts (0) — GREEN: all 42 tests pass after adding requirement to spec.json.
- **[archive_only_evidence]** verification: pnpm run check (0) — Full plugin check passes: schemas:check, typecheck, generate:manifests:check, test-isolation, lockfile-policy, lint, format:check.
- **[archive_only_evidence]** verification: tests_run=jq shape validation on .adv/specs/advance-workflow/spec.json, bin/oc-test targeted -- src/adv-autonomy-quality-assets.test.ts results=pass — JSON/shape validation passed. Targeted suite: 1 file, 42 tests passed, exit 0. Requirement is additive and compatible with rq-verificationEvidence01 and rq-TDD013evp.
- **[unresolved_action]** consumer_warnings: verification_missing: Reviewer aggregate evidence is non-authoritative; no typed adv_run_test run ID proves command: jq shape validation on .adv/specs/advance-workflow/spec.json
- **[unresolved_action]** consumer_warnings: verification_missing: Reviewer aggregate evidence is non-authoritative; no typed adv_run_test run ID proves command: bin/oc-test targeted -- src/adv-autonomy-quality-assets.test.ts
- **[archive_only_evidence]** decisions: Imported resolveTaskEvidence from plugin/src/validator/task-classifier.ts and gated the adv-reviewer verification_missing emitter on task policy. — The spec requirement rq-reviewerEvidenceAuthority01 requires review-policy tasks to treat the same-task adv-reviewer report as authoritative, so its aggregate tests_run must not emit verification_missing; test/static_check policies still require durable adv_run_test evidence.
- **[archive_only_evidence]** verification: bin/oc-test targeted -- src/tools/subagent-report.test.ts (1) — RED: new review-policy suppression test fails as expected; 65 other tests pass.
- **[archive_only_evidence]** verification: bin/oc-test targeted -- src/tools/subagent-report.test.ts (0) — GREEN: both new policy-gate tests pass; all 66 tests pass.
- **[archive_only_evidence]** verification: pnpm run check (0) — Full plugin check passes: schemas:check, typecheck, generate:manifests:check, test-isolation, lockfile-policy, lint, format:check.
- **[archive_only_evidence]** decisions: Added persisted consumer_warnings to reviewer report mocks to reflect runtime emitter behavior — checkUnresolvedVerificationEvidence reads already-computed consumer_warnings; it does not re-run verificationWarnings
- **[archive_only_evidence]** decisions: Used stage-v2 in AC4 evidence plan — Same-task ownership for review_evidence_ref is only enforced in stage-v2 branch
- **[archive_only_evidence]** verification: bin/oc-test targeted -- src/temporal/gate-readiness.test.ts (0) — GREEN: 103 tests passed in gate-readiness.test.ts (AC1 review no-block, AC2 test block, AC3 warn-first, AC4 change-scoped rejected)
- **[archive_only_evidence]** verification: pnpm run check (0) — Full plugin check passes: schemas:check, typecheck, generate:manifests:check, test-isolation, lockfile-policy, lint, format:check
- **[report_follow_up]** follow_ups: Packet scope key researcher:fixReviewerEvidence-design-validation was schema-invalid due to uppercase characters; persisted report uses normalized schema-valid key researcher:fix-reviewer-evidence-design-validation.
- **[research_citation]** sources: Verification warning emitter and submission call site: Reviewer reports unconditionally emit verification_missing today; task is loaded from a valid task anchor before the warning function is called. (plugin/src/tools/subagent-report.ts:470-480,845-882)
- **[research_citation]** sources: Normalized evidence resolver and completion ownership: resolveTaskEvidence is exported, pure, takes Task, resolves a policy through declared/default policy, and stage-v2 reviewer evidence must be same-task and adv-reviewer-owned. (plugin/src/validator/task-classifier.ts:255-327,350-407)
- **[research_citation]** sources: Readiness evaluator: Acceptance/release blocking consumes persisted latest task-scoped verification warnings only for proof-bearing policies; it need not change if review-policy reviewer warnings are not emitted. (plugin/src/temporal/gate-readiness.ts:642-733)
- **[research_citation]** sources.omitted: 2 additional sources omitted (bounded to first 3)
- **[archive_only_evidence]** architecture_assessment: APPROVE. The consumer-side policy gate is the narrowest correct boundary: report submission has the resolved task object, while readiness remains a generic latest-warning evaluator. Direct import from validator/task-classifier introduces no observed cycle because the resolver depends only on types and no validator source imports tools/subagent-report.

## Contract / AC Coverage

| ID | Kind | Status |
| --- | --- | --- |
| AC1 | acceptance_criterion | pass |
| AC2 | acceptance_criterion | pass |
| AC3 | acceptance_criterion | pass |
| AC4 | acceptance_criterion | pass |
| AC5 | acceptance_criterion | pass |
| C1 | constraint | respected |
| C2 | constraint | respected |
| C3 | constraint | respected |
| C4 | constraint | respected |
| C5 | constraint | respected |
| DONT1 | avoidance | respected |
| DONT2 | avoidance | respected |
| DONT3 | avoidance | respected |
| OOS1 | out_of_scope | missing |
| OOS2 | out_of_scope | missing |
| OOS3 | out_of_scope | missing |

## Unresolved Actions

- verification_missing: Reviewer aggregate evidence is non-authoritative; no typed adv_run_test run ID proves command: jq shape validation on .adv/specs/advance-workflow/spec.json
- verification_missing: Reviewer aggregate evidence is non-authoritative; no typed adv_run_test run ID proves command: bin/oc-test targeted -- src/adv-autonomy-quality-assets.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Contract Traceability

**Change ID:** fixReviewerEvidence
**Contract Version:** 1
**Rigor:** standard
**Reviewed:** 2026-07-25T21:18:01.368Z

## Contract Items

| ID | Kind | Status | Evidence Policy | Evidence |
| --- | --- | --- | --- | --- |
| AC1 | acceptance_criterion | pass | test | subagent-report + gate-readiness tests. tr_ms0ujmvp, tr_ms0v2cg0. |
| AC2 | acceptance_criterion | pass | test | gate-readiness AC2 regression. tr_ms0v2cg0. |
| AC3 | acceptance_criterion | pass | test | gate-readiness AC3 warn-first. tr_ms0v2cg0. |
| AC4 | acceptance_criterion | pass | test | gate-readiness AC4 change-scoped rejected. tr_ms0v2cg0. |
| AC5 | acceptance_criterion | pass | test | subagent-report TDD red->green. tr_ms0ujmvp. |
| C1 | constraint | respected | static_check | task-classifier.ts:382-394 unchanged. |
| C2 | constraint | respected | static_check | subagent-reports.ts:50-67,471-477 unchanged. |
| C3 | constraint | respected | static_check | subagent-report.ts:493-587 unchanged. |
| C4 | constraint | respected | static_check | Direction (2) rejected; no auto-record. |
| C5 | constraint | respected | static_check | subagent-reports.ts:471-477 unchanged. |
| DONT1 | avoidance | respected | review | AC2 confirms block for test/static_check. |
| DONT2 | avoidance | respected | review | Direction (2) rejected. |
| DONT3 | avoidance | respected | review | Direction (3) rejected. |
| OOS1 | out_of_scope | missing | not_applicable | |
| OOS2 | out_of_scope | missing | not_applicable | |
| OOS3 | out_of_scope | missing | not_applicable | |

## Task References

| Task | Implements | Verifies | Respects | N/A Reason |
| --- | --- | --- | --- | --- |
| tk-f0b4525a6dd8 | | | C1, C2, C5 | |
| tk-feabc293e2b7 | AC1, AC5 | AC1, AC5 | C1, C3, C4, DONT1, DONT2 | |
| tk-0c23472dfede | | AC2, AC3, AC4 | C2, C5 | |
25 changes: 25 additions & 0 deletions .adv/archive/2026-07-26-fixReviewerEvidence/acceptance.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Acceptance

Reviewed at: 2026-07-25T21:18:01.368Z

## Contract Review Matrix

| ID | Kind | Requirement | Status | Evidence |
|---|---|---|---|---|
| AC1 | acceptance_criterion | **AC1** — Given a done stage-v2 code task with `evidence_policy: review` and a persisted same-task `adv-reviewer` report, when acceptance or release readiness runs, then no `VERIFICATION_EVIDENCE_MISSING` blocker is emitted solely from the reviewer's aggregate `tests_run` list. *(Regression test: red → green.)* | pass | subagent-report + gate-readiness tests. tr_ms0ujmvp, tr_ms0v2cg0. |
| AC2 | acceptance_criterion | **AC2** — Given a done task with `evidence_policy: test` or `evidence_policy: static_check` whose only evidence is a reviewer aggregate command list (no durable `adv_run_test` run), when readiness runs, then the block remains (`VERIFICATION_EVIDENCE_MISSING` still fires). Reviewer prose does not satisfy these policies. | pass | gate-readiness AC2 regression. tr_ms0v2cg0. |
| AC3 | acceptance_criterion | **AC3** — Given a done task with `evidence_policy: source_audit` or `evidence_policy: rubric_review`, when reviewer warnings exist, then no verification-evidence blocker is emitted. *(Already the case today; regression-protect.)* | pass | gate-readiness AC3 warn-first. tr_ms0v2cg0. |
| AC4 | acceptance_criterion | **AC4** — Given a change-scoped `adv-reviewer` report, when task completion validation runs, then it cannot satisfy the task's `review_evidence_ref`. Same-task ownership is preserved. | pass | gate-readiness AC4 change-scoped rejected. tr_ms0v2cg0. |
| AC5 | acceptance_criterion | **AC5** — The `verification_missing` emitter in `plugin/src/tools/subagent-report.ts` is policy-gated: it fires `verification_missing` for `test`/`static_check` evidence policies but suppresses it for `review` policy when the report originates from `agent: "adv-reviewer"`. | pass | subagent-report TDD red->green. tr_ms0ujmvp. |
| C1 | constraint | **C1** — Same-task reviewer ownership and `adv-reviewer` identity for `review_evidence_ref` must be preserved (`task-classifier.ts:382-394`). | respected | task-classifier.ts:382-394 unchanged. |
| C2 | constraint | **C2** — No change-scoped report may satisfy task-level reviewer evidence linkage (`subagent-reports.ts:50-67, 471-477`). | respected | subagent-reports.ts:50-67,471-477 unchanged. |
| C3 | constraint | **C3** — `test` / `static_check` policies remain backed by independently durable execution evidence (`test.ts:484-558`); reviewer aggregate command prose cannot satisfy them. | respected | subagent-report.ts:493-587 unchanged. |
| C4 | constraint | **C4** — No fake `adv_run_test` records may be synthesized from report-submitted command claims. Auto-recording reviewer commands as `adv_run_test` runs is explicitly rejected (direction 2). | respected | Direction (2) rejected; no auto-record. |
| C5 | constraint | **C5** — Existing acceptance-summary `review:acceptance` boundary remains separate and unchanged (`subagent-reports.ts:471-477`). | respected | subagent-reports.ts:471-477 unchanged. |
| DONT1 | avoidance | **DONT1** — Do not extend the reviewer-authority exception to `test` or `static_check` policies. Those still require durable execution evidence from `adv_run_test` or equivalent capture. | respected | AC2 confirms block for test/static_check. |
| DONT2 | avoidance | **DONT2** — Do not auto-record `adv_run_test` runs from reviewer report claims. Reviewer reports carry aggregate `tests_run: string[]` without per-command exit codes, typed run IDs, duration, or execution classification. Writing `adv_run_test` records from these claims would falsely represent execution and bypass `adv_run_test`'s capture path. | respected | Direction (2) rejected. |
| DONT3 | avoidance | **DONT3** — Do not add a new duplicate authority field or signal. `review_evidence_ref` already provides typed reviewer ownership, same-task binding, and stage-v2 completion proof. A second "accepts-verification" path duplicates authority without adding a missing identity boundary. | respected | Direction (3) rejected. |
| OOS1 | out_of_scope | **OOS1** — Schema gap in `ChangeScopedReviewerSubagentReportSchema` not enforcing reviewer-key pairing (`subagent-reports.ts:57-62, 471-477, 783-791`). Different defect; track separately. | missing | |
| OOS2 | out_of_scope | **OOS2** — Reviewer agent behavior changes (reviewer still runs commands and reports them as aggregate verification). | missing | |
| OOS3 | out_of_scope | **OOS3** — Evidence policy taxonomy redesign. | missing | |

Loading
Loading