# Issue 24743: focused red/green orchestration runtime evidence

Captured 2026-10-26 UTC in /home/ubuntu/wt/issue-24743. Visual matrix: 0/0 rows (server-only; supplied matrix empty). This is the accepted focused integration-runtime fallback.

## Revisions and exact command

- Baseline supplied: [dd5b5401e1](https://git.cafe/pingdotgg/t3code/commit/dd5b5401e1).
- Red test commit: [2bcb5517dc](https://git.cafe/pingdotgg/t3code/commit/2bcb5517dce68f352479e71f3e51c072e2170c3d), full SHA 2bcb5517dce68f352479e71f3e51c072e2170c3d; baseline implementation with regression tests added.
- Green: [441ade6ed1](https://git.cafe/pingdotgg/t3code/commit/441ade6ed192ac67bf5753a06ef30c6a2cde0f55), full SHA 441ade6ed192ac67bf5753a06ef30c6a2cde0f55 on fix/issue-24743.
- Regression test file is identical between these two commits (git diff returned empty).

Executed at both revisions from the worktree root:

```sh
vp test run apps/server/src/orchestration-v2/DelegatedCompletionDelivery.test.ts -t 'settled between' --reporter=verbose
```

- [Raw red stdout/stderr and invocation](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/23c04465151d1883/red.log): exit 1, 2 failed / 28 filtered skips.
- [Raw green stdout/stderr and invocation](https://gh-file-drop-api-prod-mi5fy3sowv63ufte.pinglabs.workers.dev/f/665e4226259218c2/green.log): exit 0, 2 passed / 28 filtered skips.

Logs include UTC invocation time, working directory, full HEAD SHA, exact argv, verbose test output, assertions, and test-command exit status. The capture wrapper itself succeeds independently; EXIT STATUS records the test subprocess status.

## Event order and persisted results

The tests seed a parent run plus terminal delegated task. The real orchestrator dispatches delegated_task.completion-delivery.acknowledge, the path used by task_status. A commitCommand spy deterministically inserts a settling run.updated commit after acknowledge reads the parent and before acknowledge commits. It invokes the original EventSink commit for both operations; there are no timing sleeps or polling. The settled assertion confirms the insertion occurred before checking the resulting run projection.

1. Acknowledge reads running (or waiting).
2. The original EventSink commits failed with completedAt, or completed with completedAt and checkpoint:ack-settle-race-completed.
3. Acknowledge commits its previously read snapshot.
4. The test rereads the persisted projection through getThreadProjection and asserts status, completedAt, checkpointId.

| Case | Red actual persisted projection | Green asserted persisted projection |
| --- | --- | --- |
| failed settlement | status running; completedAt null; checkpointId null | status failed; completedAt 1970-01-01T00:00:00.000Z; checkpointId null |
| completed settlement | status waiting; completedAt null; checkpointId null | status completed; completedAt 1970-01-01T00:00:00.000Z; checkpointId checkpoint:ack-settle-race-completed |

Red fails on these final deep-equality assertions, not setup. Green retains the settling state. The fixed EventSink merges delegatedCompletion against the current run inside the commit transaction, preserving concurrent settlement fields.

## Scope and limits

This executes real Orchestrator, EventSink, and projection runtime with SQLite in-memory persistence in the integration test harness. Settling events are hand-built run.updated events matching the writer outcomes. The transcript reports test assertions over the persisted projection; it is not a separate database dump or full event-log export.

No real Codex/provider execution, rate-limit reproduction, live server replay, browser, desktop, or mobile session occurred. Provider adapter decoding and actual checkpoint capture are not exercised by these two cases. Independent Stop behavior and queue recovery are not separately proven. Filtered skips are not executed coverage. No visual evidence applies: 0/0 visual rows.

## Restoration and changes

Restored fix/issue-24743 at exactly 441ade6ed192ac67bf5753a06ef30c6a2cde0f55; git status --short is empty. No implementation/test edits, commits, pushes, or PR operations. What else changed: none. Capture scratch is removed after upload; the pre-existing historical red report belongs to the lead and is untouched. Uploaded logs were inspected in full and contain test fixtures, stack traces, paths, and command metadata; no secrets found.

## FRICTION

- No browser was available; the explicitly accepted focused orchestration integration-runtime fallback was used.
- Vite+ prints an informational built-in-command notice; the requested command correctly ran only the two matching regressions. No setup, dependency installation, or command workaround was needed.
