* fix(codex): report harness context window as session contextTokens
Codex app-server reports model_context_window per turn. Carry it through the projector into the run result meta so session rows show the real window instead of the catalog's standard-tier input cap (272k vs 1M for gpt-5.6 models).
* improve(ui): compact chat context popover
Inline stat rows replace boxed tiles; zero-value cost rows and the whole cost section when empty are omitted; provider/model provenance lines are removed because the footer already shows the model; and the popover is narrowed to 300px.
* refactor(codex): split attempt-result assembly out of event projector
* fix(codex): seed attempt context window from startup binding
App-server v2 turn/started omits the core model_context_window, so thread/tokenUsage/updated is the only live carrier. Seed usage-less attempts from the retained startup binding rollout/session window so session metadata cannot regress to the catalog fallback.
* fix(codex): prefer native startup context window
Persisted session contextTokens has no source provenance and may contain the catalog fallback. Keep the minimum window for the conservative rotation fuse, but seed the projector from the native rollout when it is available.
* chore(plugin-sdk): regenerate api baseline (new format)
* revert(gateway): "prevent restart replay after final delivery" (broke 5 CI jobs)
Treat message(final=false) as progress and final=true or omission as the terminal source reply. Repeated terminal delivery now returns a non-error outcome without another provider send.
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
Co-authored-by: 宇宙熊Yzx <53250620+849261680@users.noreply.github.com>
Co-authored-by: Markus <markuscontasul@gmail.com>
* feat(ui): show unsent-draft pencil on sidebar session rows
Typed-but-unsent composer text now surfaces as a pencil badge on the
owning session's sidebar row (and Home row) once you switch away.
Draft persistence now notifies stored-outbox subscribers so the
indicator appears and clears live. The active session suppresses the
badge since its composer is already visible.
* chore: refresh merge ref for CI against current main
* chore: refresh merge ref against healed main
* fix(ui): notify draft indicator only on presence transitions
Unconditional notify on every draft persist let outbox-projection
subscribers re-persist a stale pane over a newer draft (chat-state
route-fallback invariant). The sidebar pencil only consumes presence,
so notify on empty/non-empty transitions only.
- forward taskSuggestionDeliveryMode through the Codex app-server dynamic tool build (same sibling-harness omission class previously fixed for clientCaps); spawn_task/dismiss_task silently never existed for GPT-backed sessions
- regression test asserting the forward, mirroring the existing clientCaps case
- spawn_task/dismiss_task descriptions rewritten with usage calibration: when to flag, when not to, scope-vs-flagging, prose-is-lost, operator-phrasing bridge, prompt self-containment, git-checkout cwd, registry ephemerality; param descriptions state where each field renders
Release-note context: GPT-backed sessions can now create suggested-task cards (the tools were silently absent on the Codex harness), and the tools carry much clearer model-facing guidance.
Record channel delivery custody before recipient-visible sends so restart recovery cannot duplicate accepted finals.
Ambiguous legacy markers now fail closed with a visible interruption instead of blind replay.
Co-authored-by: Ayaan Zaidi <hi@obviy.us>
* fix(gateway): unify media privacy in chat history
Centralize image, audio, video, and persisted media-fact privacy at the shared Gateway history projection. Remove duplicate sessions_history redaction, validate managed media claims canonically, and keep safe media-only user turns renderable.
* test(gateway): type history RPC integration
* test(agents): align history fixture with gateway projection
Before returning a successful immutable ownership result, recheck whether a WAL appeared and rerun through SQLite normal read-only access. Add a deterministic real-SQLite regression that commits the ownership row after the immutable connection opens.
Keep the immutable-first ownership probe and WAL-aware corruption retry in one bounded connection loop. The selected location makes the retry single-shot while preserving handle cleanup and the no-mutation cold-family path.
Poll both fixed-width selection rails together and compare their trailing edges so the browser assertion measures settled popover geometry instead of sampling different points in the open animation.
Retry an immutable ownership probe through SQLite normal read-only access when a WAL appears during the open and produces a false corruption result. Treat a WAL without SHM as live state, and cover that rebuildable-index boundary with a real database-family regression.
Treat only live WAL sidecars as requiring a normal read-only ownership connection. Keep rollback journals on immutable preflight inspection so the canonical writable lifecycle remains the sole owner of crash recovery.
Use WAL-aware read-only access when SQLite journal sidecars are live, while retaining immutable inspection for quiescent database families. This prevents false corruption during concurrent state initialization without mutating cold databases or changing the schema.
Keep Web Awesome checkbox semantics while rendering the selection state in the sidebar filter shared trailing rail. Add mocked-browser coverage for the hidden native mark and one-pixel alignment invariant.
Co-authored-by: Vyctor H. Brzezowski <krzyszchweski@gmail.com>
* fix: exec approvals fail with a pairing prompt when the device pairing lacks operator.approvals
Local approval-runtime gateway calls sent the shared device identity in
addition to the process-local approval-runtime token, so the connect was
re-evaluated against that device paired scope baseline and rejected with
"scope upgrade pending approval" whenever operator.approvals was missing
from the pairing record. Nothing could clear it from inside the session:
the prompt that would approve the upgrade is delivered by the call that
was rejected.
Make the two requester credentials exclusive by passing the resolved
approval-runtime token into the identity resolver, matching the rule
createOperatorApprovalsGatewayClient already follows. Remote,
env-selected, and gatewayUrl-override approval calls still require a
stable device identity, as does approved node.invoke system.run replay.
Closes#121525
* fix(lint): drop dead applySessionHints import in media-only reply test
4b0151682e removed the only use of applySessionHints from this test but
left the import, so oxlint fails no-unused-vars on main and blocks the
merge gate. The vi.mock("./body.js") factory keeps the entry because
get-reply-run-context.ts still calls it.