Files
gstack/test/fixtures/coverage-diagram-legend-as.json
Garry TanandOpenAI Codex 9f81911136 v1.86.0.0 feat: route outside reviews by harness (#2850)
* feat: add a restricted and supervised Claude Code runner

Preserve configured authentication and models while enforcing tool access, strict completion JSON, bounded output and process cleanup. Cover argv, failure handling, session metadata and Windows process containment.

* feat: route outside reviews by harness and migrate wrapper installs

Use Claude Code from Codex and Codex from other supported hosts, with shared invocation rendering, positive gate validation and per-phase provenance. Rename /claude to /claude-code, repair managed shared and copied installations safely, and generate native Kiro skills. Add installed-workflow, failure-injection and live cross-harness regression coverage.

* test: recognize CEO mode labels without terminal spacing

The paid workflow rendered SCOPEEXPANSION at option 4, but its driver required a literal space. Match the leading mode title without cursor-spacing artifacts and ignore adjacent preview text. Preserve missing-target failures and downstream posture assertions.

* test: isolate plan-count fixtures before starting review workflows

Seed the complete test plan in a private git repository before launching Claude, so a bare slash command cannot review the live workspace while a delayed fixture message remains queued. Preserve count thresholds, parsers and budgets. Add initial-context and installed-discovery tests, and retain startup/terminal diagnostics on failed evaluations.

* test: stabilize review fixtures and Claude eval startup

Preserve source boundaries in workflow judge inputs, isolate CEO mode plans, and wait for interactive trust input readiness. Keep startup failure evidence and retain existing models, budgets, and assertions.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: classify collapsed review modes and isolate seeded findings

Keep review questions out of the setup count when terminal cursor positioning removes spaces. State existing webhook safeguards so the five-finding control measures its seeded defects without accidental extra security and concurrency gaps. Preserve question bands and the paired control.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: isolate browser daemon state across free shards

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: stabilize native review counting and interactive navigation

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* chore: prepare v1.82.0.0 release

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* fix: eliminate browser and process-cleanup test flakes

Pin every CI surface to Bun 1.4.0 to avoid extra-stdio finalizers closing
reused live sockets. Add an isolated GC/listener regression that fails on
Bun 1.3.13, and prevent coordinated rollback to an affected CI runtime.

Check renderer cleanup against the render's own staging directory so
concurrent renders cannot invalidate the assertion. Make the no-pgrep
process-tree walk tolerate disappearing /proc entries, and synchronize
its test fixture through child readiness and pipe EOF instead of sleeps.

Validation: 9,157 passed, 31 skipped, zero failures across 556 files with
retries disabled. Build, all-host generation freshness, and skill checks
passed. All three races have failing-before/passing-after regressions.

* fix: count completed native review questions in evals

* fix: drive review navigation from confirmed native choices

* fix: require complete section-loading eval reports

* test: isolate telemetry HTTP transport from local assertions

* fix: keep review input on the active native question

* test: let tunnel revocation daemon choose an available port

* test: allocate available ports for pairing and watchdog fixtures

* fix: stabilize planning eval navigation and phase reporting

* test: isolate installed runtime paths in planning evals

* test: stabilize review evidence and concurrent refresh fixtures

* fix: resolve design findings before editing the plan

* fix: honor and persist disabled outside plan reviews

* fix: preserve planning decisions and terminal evidence

Load installed host reviews at autoplan phase entry and wait for completed
reviewers and saved artifacts. Reuse approved remedies while preserving
individual finding decisions.

Drive interactive evals from the current terminal viewport, bind native
questions across scrolling, and require complete native report evidence.
Cover captured stale menus, permission lifecycles, setup classification,
and disabled-review tool availability with deterministic regressions.

Advance release metadata and the upgrade migration to the unclaimed
1.83.0.0 slot.

* fix: drive native review questions and preserve current plans

Use the native single-choice keyboard protocol and current terminal viewport,
with per-question navigation inside packets and completed-call coverage.
Keep permissions, multi-select menus, and Submit controls distinct.

Send Autoplan reviewers the amended implementation plan, keep its review record
separate, and supply retained application contracts in the chain fixture.
Clarify individual DevEx decisions and complete CEO fix options; use one active
plan destination for the section-loading report.

* fix: preserve complete plan-review decisions

* fix: recognize native plan dialogs and reviewer controls

* fix: preserve review decisions and phase completion

* fix: recognize completed reviews without losing findings

* fix: preserve review continuity and native eval completion

* test: fix native review completion and eval retry isolation

* test: handle native review menus and complete eval fixtures

* test: fix native review setup, completion, and isolation failures

* test: limit native skill discovery to runtime assets

* fix: bind Autoplan reviews to full ordered phase inputs

* test: fix planning eval routing, counting, and timeout handling

* chore: advance queued release to v1.84.0.0

* fix: preserve complete review inputs and planning decisions

* fix: reconcile review approvals and preserve phase obligations

* fix: preserve review obligations and unblock eval permissions

Carry recorded Autoplan requirements into blind phase inputs, require Eng
review approvals before exit, and exercise combined asynchronous flows in
CEO reviews. Correct native finding and handoff classification and unblock
repeated report edits using scoped request identities.

* fix: retain plan requirements and complete native review dialogs

* fix: complete native review prompts and retain plan references

* fix: preserve review inputs and classify native eval evidence

* fix: check competing completion orders in CEO reviews

* fix: recognize review decisions and require phase methodology

Require the current phase methodology before Autoplan snapshots. Correct
substantive decision, closed handoff, and cache-finding classification, and
honor the recommended implementation approach in native review dialogs.

Add captured-transcript regressions without changing review thresholds,
provider models, retries, or deadlines.

* test: bind native review decisions and close completed handoffs

* fix: complete review dialogs and verify methodology delivery

* fix: preserve review evidence and unblock native eval prompts

* fix: handle native review question completions

* fix: recognize native review narration and controls

* fix: count native review decisions and isolate eval fixtures

* test: verify seeded review coverage and current artifact permissions

* test: isolate model and brain-aware skill renders

* fix: repair native workflow evaluation and clarify review steps

* fix: stabilize workflow eval evidence and review guidance

* test: repair native workflow observation and fixture isolation

* fix: recognize completed workflow evidence and owned skill reads

* test: repair seeded workflow delivery and completion evidence

* test: recognize current review evidence across native forms

* test: handle native review variants and permission redraws

* fix: honor review preferences and recognize native eval evidence

* test: recognize completed review decisions and queued permissions

* test: match current review contracts and partial-line edits

* test: recognize completed workflow evidence and bounded human waits

* fix: preserve review entry gates and native eval interactions

* fix: recognize native workflow evidence and preserve review gates

* test: recognize current review evidence and preconfigure workflow fixtures

* test: recognize completed review findings and scoped artifact permissions

* fix: stabilize native workflow review and permission evidence

* fix: recognize current review evidence and scoped edit confirmations

Clarify Design and engineering review entry instructions and Design scoring.
Recognize required legacy coverage and public Autoplan completion recaps.
Bind the pending Edit confirmation to its exact file, ordered digest, and
one-request approval when a preceding command display remains visible.
Keep reviews within their existing size limits and preserve scope gates
when extracting workflow fixtures from either supported preamble header.

Keep failure outcomes, review thresholds, provider choices, and eval budgets.

* fix: recover review workflow progress and eval evidence

* fix: recognize valid review evidence and scope selection

* test: fix review evidence parsing and repeated artifact prompts

* test: recognize valid review decisions and pending native cards

* fix(plan-eng-review): keep final navigation consistent with approved tasks

* test: recognize valid review evidence and bind legacy diff requests

* fix: stabilize review eval evidence and harness repair guidance

* docs: update project documentation for v1.85.0.0

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* test: fix Windows CI fixtures and credential scan

Rebase captured JSON values and filesystem evidence using the appropriate
path convention. Compile native fake CLIs on Windows and synchronize pipe
holder readiness, with cleanup retained when assertions fail.

Assemble synthetic credential fixtures at runtime so the added-line scan
keeps enforcing the same gate without flagging its own rejection controls.

Discover generated skills directly for the empty-find regression check,
avoiding a recursive scan through saved evaluation artifacts and dependencies.

* fix: preserve source renders on Windows

Compare canonical generator paths using native separators so an output
sidecar pointing at the source cannot overwrite its skill or metadata.
Keep the regression fixture isolated from the real checkout and expose
freshness diagnostics before asserting subprocess status.

Detach Windows drain-test pipe holders from the fake provider's automatic
child cleanup while preserving the enclosing runner job and its assertions.

* fix: clarify outside review fallback and CEO decisions

Render one applicable own-harness fallback path and retain native review,
disabled policy, and missing-coverage semantics. Align report field names
and mode labels, and make the existing per-cut scope approval explicit.

Regenerate skill outputs and keep the workflow judge's model, thresholds,
and retry policy unchanged.

* chore: move release to free version slot (v1.86.0.0)

PR #2852 now claims v1.85.0.0. Align the release metadata and
rename migration so upgrades from that version still receive it.

Co-Authored-By: OpenAI Codex <noreply@openai.com>

* fix: include engineering review prerequisites and restore branch context

* fix: recognize coverage diagrams and clarify design review instructions

* fix: preserve file identities and join Windows test processes

---------

Co-authored-by: OpenAI Codex <noreply@openai.com>
2026-09-14 14:32:45 -07:00

125 lines
15 KiB
JSON

{
"provenance": {
"run": "ship-source-as-delta-paid-20260910-v1",
"sourceHead": "f26d569e0345cb1131d9ca52d4a43965085c3468",
"originalAttemptOutcomes": [
"failed",
"failed"
],
"paidOutcomesReclassified": false,
"projection": "Exact final public assistant text and the native parent file-read pair; init and event envelopes retain only required identity fields."
},
"rows": [
{
"attempt": 1,
"cwd": "/tmp/gstack-paid-shard-eMtnp5/tmp/skill-e2e-review-coverage-5yDBnd",
"result": {
"exitReason": "success",
"browseErrors": [],
"output": "Test coverage audit is complete. Vitest is not installed in this sandbox, so the suite could not be executed; the analysis below is static, based on reading both files.\n\n```\nTEST COVERAGE MAP \u2014 src/billing.ts (branch: feature/billing vs main)\nLegend: [\u2713] tested [\u2717] GAP \u2500\u2500\u25ba branch\n\nsrc/billing.ts\n\u2502\n\u251c\u2500\u2500 processPayment(amount, currency) 1 of 3 paths tested\n\u2502 \u2502\n\u2502 \u251c\u2500\u2500\u25ba line 3 amount <= 0 \u2192 throw 'Invalid amount' [\u2717] GAP Missing Negative-Path\n\u2502 \u2502 zero / negative boundary never exercised\n\u2502 \u2502\n\u2502 \u251c\u2500\u2500\u25ba line 4 currency \u2209 {USD, EUR} \u2192 throw [\u2717] GAP Missing Negative-Path\n\u2502 \u2502 'Unsupported currency' (e.g. 'GBP', '')\n\u2502 \u2502\n\u2502 \u2514\u2500\u2500\u25ba line 5 return { status: 'success', ... } [\u2713] test/billing.test.ts:6\n\u2502 'processes valid payment' (100, 'USD')\n\u2502 note: only USD covered; EUR happy path untested\n\u2502\n\u2514\u2500\u2500 refundPayment(paymentId, reason) 0 of 3 paths tested\n \u2502 [\u2717] GAP Coverage Gap\n \u2502 exported function, never imported by any test\n \u2502\n \u251c\u2500\u2500\u25ba line 9 !paymentId \u2192 throw 'Payment ID required' [\u2717] GAP Missing Negative-Path\n \u2502\n \u251c\u2500\u2500\u25ba line 10 !reason \u2192 throw 'Reason required' [\u2717] GAP Missing Negative-Path\n \u2502\n \u2514\u2500\u2500\u25ba line 11 return { status: 'refunded', ... } [\u2717] GAP Coverage Gap\n\n\nSUMMARY\n Functions exported ........ 2 covered: 1 uncovered: 1\n Branches / paths .......... 6 covered: 1 uncovered: 5\n Guard clauses ............. 4 covered: 0 uncovered: 4\n Error branches tested ..... 0 of 4\n```\n\nFindings, ranked by severity:\n\n- **refundPayment has zero coverage** (Coverage Gaps). A new public function is exported and never imported in the test file. Both guard clauses and the success return are unverified.\n- **processPayment rejects are untested** (Missing Negative-Path Tests). Both throw branches at lines 3 and 4 have no failing-input test. A regression that removes either guard would pass the suite.\n- **Happy path is narrow.** The one existing test covers only USD. The EUR branch of the currency check is accepted by code but never asserted.\n\nSuggested test stubs to close the gaps:\n\n```ts\nimport { processPayment, refundPayment } from '../src/billing';\n\ntest('rejects zero amount', () => expect(() => processPayment(0, 'USD')).toThrow('Invalid amount'));\ntest('rejects negative amount', () => expect(() => processPayment(-5, 'USD')).toThrow('Invalid amount'));\ntest('rejects unsupported currency', () => expect(() => processPayment(10, 'GBP')).toThrow('Unsupported currency'));\ntest('accepts EUR', () => expect(processPayment(10, 'EUR').currency).toBe('EUR'));\n\ntest('refunds valid payment', () => expect(refundPayment('p1', 'dup').status).toBe('refunded'));\ntest('rejects missing paymentId', () => expect(() => refundPayment('', 'dup')).toThrow('Payment ID required'));\ntest('rejects missing reason', () => expect(() => refundPayment('p1', '')).toThrow('Reason required'));\n```\n\nOne environment note: the package.json test script only echoes \"no tests yet\" and node_modules is absent, so even the existing test does not run in CI as configured.",
"transcript": [
{
"type": "system",
"subtype": "init",
"cwd": "/tmp/gstack-paid-shard-eMtnp5/tmp/skill-e2e-review-coverage-5yDBnd",
"session_id": "7c7ba4bd-9818-4a7e-b3b7-ad74b24c4836"
},
{
"type": "assistant",
"session_id": "7c7ba4bd-9818-4a7e-b3b7-ad74b24c4836",
"parent_tool_use_id": null,
"message": {
"role": "assistant",
"content": [
{
"type": "tool_use",
"id": "toolu_015hqy9J6KoorxoLUuXTTEVM",
"name": "Bash",
"input": {
"command": "cat -n src/billing.ts && echo ==== && cat -n test/billing.test.ts",
"description": "Read source and test files"
},
"caller": {
"type": "direct"
}
}
]
}
},
{
"type": "user",
"session_id": "7c7ba4bd-9818-4a7e-b3b7-ad74b24c4836",
"parent_tool_use_id": null,
"message": {
"role": "user",
"content": [
{
"tool_use_id": "toolu_015hqy9J6KoorxoLUuXTTEVM",
"type": "tool_result",
"content": " 1\t\n 2\texport function processPayment(amount: number, currency: string) {\n 3\t if (amount <= 0) throw new Error('Invalid amount');\n 4\t if (currency !== 'USD' && currency !== 'EUR') throw new Error('Unsupported currency');\n 5\t return { status: 'success', amount, currency };\n 6\t}\n 7\t\n 8\texport function refundPayment(paymentId: string, reason: string) {\n 9\t if (!paymentId) throw new Error('Payment ID required');\n 10\t if (!reason) throw new Error('Reason required');\n 11\t return { status: 'refunded', paymentId, reason };\n 12\t}\n====\n 1\t\n 2\timport { describe, test, expect } from 'vitest';\n 3\timport { processPayment } from '../src/billing';\n 4\t\n 5\tdescribe('processPayment', () => {\n 6\t test('processes valid payment', () => {\n 7\t const result = processPayment(100, 'USD');\n 8\t expect(result.status).toBe('success');\n 9\t });\n 10\t // GAP: no test for invalid amount\n 11\t // GAP: no test for unsupported currency\n 12\t // GAP: refundPayment not tested at all\n 13\t});",
"is_error": false
}
]
}
}
]
}
},
{
"attempt": 2,
"cwd": "/tmp/gstack-paid-shard-eMtnp5/tmp/skill-e2e-review-coverage-5yDBnd",
"result": {
"exitReason": "success",
"browseErrors": [],
"output": "The skill docs don't prescribe a diagram format, so here is the audit in an ASCII coverage map. The branch has one commit shared with main, so the audit covers the full file rather than a diff.\n\n```\nsrc/billing.ts \u2014 test coverage map (test/billing.test.ts)\nLegend: [\u2714] tested [\u2718] GAP (no test)\n\nprocessPayment(amount, currency) 1 of 3 paths covered\n\u2502\n\u251c\u2500 if (amount <= 0) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba throw 'Invalid amount' [\u2718] GAP negative-path\n\u2502 boundary values untested: 0, -1, NaN\n\u2502\n\u251c\u2500 if (currency !== 'USD' && !== 'EUR')\n\u2502 \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba throw 'Unsupported currency' [\u2718] GAP negative-path\n\u2502 untested: 'GBP', '', 'usd' (case)\n\u2502 happy-path 'EUR' branch also untested [\u2718] GAP edge-case\n\u2502\n\u2514\u2500 return { status: 'success', amount, currency } [\u2714] processes valid payment\n (asserts only .status; amount/currency echo unchecked)\n\nrefundPayment(paymentId, reason) 0 of 3 paths covered \u2014 never imported\n\u2502\n\u251c\u2500 if (!paymentId) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba throw 'Payment ID required' [\u2718] GAP negative-path\n\u2502 untested: '', undefined\n\u2502\n\u251c\u2500 if (!reason) \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u25ba throw 'Reason required' [\u2718] GAP negative-path\n\u2502 untested: '', undefined\n\u2502\n\u2514\u2500 return { status: 'refunded', paymentId, reason } [\u2714]\u2192[\u2718] GAP coverage: public fn, zero tests\n\nSummary\n Branches: 6 total 1 covered 5 gaps\n Functions: 2 total 1 covered 1 with zero coverage\n```\n\nFindings, ranked:\n\n- **Coverage Gaps: refundPayment has zero tests.** Exported public function, never imported by the test file. Both guards and the success return are unverified.\n- **Missing Negative-Path: amount guard untested.** No test that `processPayment(0, 'USD')` or a negative amount throws. A regression to `amount < 0` would pass the suite.\n- **Missing Negative-Path: currency guard untested.** No test that an unsupported code throws. The `EUR` accept path is also unexercised, so the only value proven to work is `USD`.\n- **Missing Negative-Path: refund guards untested.** Neither the missing payment ID nor the missing reason rejection has a failing-input test.\n- **Weak assertion on the one existing test.** It checks `status` only, so a bug that drops or mutates `amount` or `currency` in the return value would go unnoticed.\n\nThe test file's own comments already acknowledge the first three gaps. Adding five `expect(() => ...).toThrow(...)` cases plus one `EUR` happy path and one `refundPayment` success case would bring every branch to covered.",
"transcript": [
{
"type": "system",
"subtype": "init",
"cwd": "/tmp/gstack-paid-shard-eMtnp5/tmp/skill-e2e-review-coverage-5yDBnd",
"session_id": "b36532b9-369f-4dc3-ba70-197663bdfee6"
},
{
"type": "assistant",
"session_id": "b36532b9-369f-4dc3-ba70-197663bdfee6",
"parent_tool_use_id": null,
"message": {
"role": "assistant",
"content": [
{
"type": "tool_use",
"id": "toolu_01XBJKThc7uaHKvMwCYY9oxC",
"name": "Bash",
"input": {
"command": "cat review/specialists/testing.md; echo ======; cat -n src/billing.ts; echo ======; cat -n test/billing.test.ts",
"description": "Read testing specialist, source, and tests"
},
"caller": {
"type": "direct"
}
}
]
}
},
{
"type": "user",
"session_id": "b36532b9-369f-4dc3-ba70-197663bdfee6",
"parent_tool_use_id": null,
"message": {
"role": "user",
"content": [
{
"tool_use_id": "toolu_01XBJKThc7uaHKvMwCYY9oxC",
"type": "tool_result",
"content": "# Testing Specialist Review Checklist\n\nScope: Always-on (every review)\nOutput: JSON objects, one finding per line. Schema:\n{\"severity\":\"CRITICAL|INFORMATIONAL\",\"confidence\":N,\"path\":\"file\",\"line\":N,\"category\":\"testing\",\"summary\":\"...\",\"fix\":\"...\",\"fingerprint\":\"path:line:testing\",\"specialist\":\"testing\"}\nOptional: line, fix, fingerprint, evidence, test_stub.\nIf no findings: output `NO FINDINGS` and nothing else.\n\n---\n\n## Categories\n\n### Missing Negative-Path Tests\n- New code paths that handle errors, rejections, or invalid input with NO corresponding test\n- Guard clauses and early returns that are untested\n- Error branches in try/catch, rescue, or error boundaries with no failure-path test\n- Permission/auth checks that are asserted in code but never tested for the \"denied\" case\n\n### Missing Edge-Case Coverage\n- Boundary values: zero, negative, max-int, empty string, empty array, nil/null/undefined\n- Single-element collections (off-by-one on loops)\n- Unicode and special characters in user-facing inputs\n- Concurrent access patterns with no race-condition test\n\n### Test Isolation Violations\n- Tests sharing mutable state (class variables, global singletons, DB records not cleaned up)\n- Order-dependent tests (pass in sequence, fail when randomized)\n- Tests that depend on system clock, timezone, or locale\n- Tests that make real network calls instead of using stubs/mocks\n\n### Flaky Test Patterns\n- Timing-dependent assertions (sleep, setTimeout, waitFor with tight timeouts)\n- Assertions on ordering of unordered results (hash keys, Set iteration, async resolution order)\n- Tests that depend on external services (APIs, databases) without fallback\n- Randomized test data without seed control\n\n### Security Enforcement Tests Missing\n- Auth/authz checks in controllers with no test for the \"unauthorized\" case\n- Rate limiting logic with no test proving it actually blocks\n- Input sanitization with no test for malicious input\n- CSRF/CORS configuration with no integration test\n\n### Coverage Gaps\n- New public methods/functions with zero test coverage\n- Changed methods where existing tests only cover the old behavior, not the new branch\n- Utility functions called from multiple places but tested only indirectly\n======\n 1\t\n 2\texport function processPayment(amount: number, currency: string) {\n 3\t if (amount <= 0) throw new Error('Invalid amount');\n 4\t if (currency !== 'USD' && currency !== 'EUR') throw new Error('Unsupported currency');\n 5\t return { status: 'success', amount, currency };\n 6\t}\n 7\t\n 8\texport function refundPayment(paymentId: string, reason: string) {\n 9\t if (!paymentId) throw new Error('Payment ID required');\n 10\t if (!reason) throw new Error('Reason required');\n 11\t return { status: 'refunded', paymentId, reason };\n 12\t}\n======\n 1\t\n 2\timport { describe, test, expect } from 'vitest';\n 3\timport { processPayment } from '../src/billing';\n 4\t\n 5\tdescribe('processPayment', () => {\n 6\t test('processes valid payment', () => {\n 7\t const result = processPayment(100, 'USD');\n 8\t expect(result.status).toBe('success');\n 9\t });\n 10\t // GAP: no test for invalid amount\n 11\t // GAP: no test for unsupported currency\n 12\t // GAP: refundPayment not tested at all\n 13\t});",
"is_error": false
}
]
}
}
]
}
}
]
}