Repository navigation
refactor(ui): bind chat recovery and icons to Solid owners - #176375
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c732c916ed
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| setRevision(requestedGeneration); | ||
| // Invalidation samples visibility without subscribing its synchronous domain caller. | ||
| if (untrack(options.presented)) { | ||
| if (options.presented()) { |
There was a problem hiding this comment.
Keep presentation sampling out of caller tracking
When ChatThread evaluates its contents memo, renderRows() reaches ChatTranscriptRenderer.render(), which queues an after-commit task and calls this invalidate(). Reading options.presented() here therefore subscribes that outer render memo to the retained transcript root's presentation signal. A presentation-owner event can then rerender and reveal the transcript immediately with the previous pane snapshot, instead of waiting for the parent's next props as the presentation contract requires. Preserve the deliberate untracked sample (or move it outside the caller's reactive computation).
AGENTS.md reference: ui/AGENTS.md:L5-L5
Useful? React with 👍 / 👎.
| !previous.pending && | ||
| !previous.refreshing && | ||
| continuationInFlight !== current && | ||
| refreshInFlight !== current && |
There was a problem hiding this comment.
Recheck terminal receipts after refresh settles
If reconcileMutation() publishes a matching failed/timeout/killed row before its promise settles, this derivation observes it while pending or refreshing is still true and discards it. The later setPresentation calls that clear those local flags do not change the authoritative deps.source() dependency, so the terminal receipt is not reconsidered until an unrelated source publication; the dialog can remain stuck on the disabled “Waiting” state even though the Gateway already reported failure. Re-evaluate the current row when the pending flags settle rather than requiring another roster publication.
AGENTS.md reference: ui/AGENTS.md:L16-L18
Useful? React with 👍 / 👎.
|
Codex review: needs changes before merge. What this changesThis PR binds chat recovery, provider-review presentation, plugin icons, and pending-session cleanup to their Solid owners. Example: A saved queued message has sendRunId "pending-delivery".
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Needs changes before merge - 4 items remain Keep this maintainer-authored PR open: the ownership refactor is useful, but two introduced reactive-dependency defects need repair before merging. Priority: P2 Before merge
Findings
Provenance
Tests
Agent review detailsHow this fits togetherThe Control UI consumes Gateway session facts and browser recovery storage, then renders retained chat panes, continuation controls, and plugin artwork while preserving synchronous mutation admission. flowchart TD
A[Gateway session facts] --> B[Synchronous chat owners]
C[Browser recovery storage] --> D[Recovery owner]
B --> D
B --> E[Solid projections and bindings]
D --> F[Retained chat pane]
E --> F
F --> G[Explicit continuation requests]
Technical reviewBest possible solution: Keep the owner-scoped refactor while restoring untracked lifecycle sampling and terminal-receipt reconciliation when continuation work settles. Do we have a high-confidence way to reproduce the issue? Both failing paths can be traced through production callers without executing target code; exact-head CI also records extra transcript renders. Is this the best way to solve the issue? The existing owners support this refactor, but removing deliberate tracking isolation and replacing settlement-sensitive reconciliation with a source-only derivation breaks their contracts. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 53395d97c193. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceAcceptance criteria:
What I checked:
Likely related people:
PR surfaceSource -9, Tests +47. Total +38 across 8 files. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 18, 2026, 4:19 PM ET / 20:19 UTC. |
|
Merged via explicitly authorized admin squash with attributed pre-existing CI failures.
|
…176375) * refactor(ui): bind chat recovery and icons to Solid owners * fix(ui): keep render invalidation telemetry untracked * test(ui): settle primary selection before fallback edit
What Problem This Solves
Chat recovery, provider-review notices, and plugin tool icons still carried effect-driven state and lifetime wiring after the Solid migration. Recovery and icon requests now live with their binding, provider-review presentation derives from canonical terminal receipts, and pane presentation consumes the existing owner projection.
Recovery observes the chat-run owner directly and retires only durable matching user receipts. Host/identity replacement disposes outstanding work. Tool icons retain one abortable request context per connection/session binding and release blob URLs during computation cleanup through the canonical
PluginIconOwner. A terminal provider-review receipt stays visible across later row snapshots; explicit retry obtains a fresh idempotency key. Render invalidation telemetry reuses committed-generation state, preserving live visibility checks before layout callbacks.Host tags, markup, styling, routes, and lazy boundaries are unchanged. The obsolete recovery
messagesbridge property is removed with its sole caller. No new dependencies or options. Main integration preserves its completed icon-owner rename; the conflict resolution changes only that import and constructor relative to the previously reviewed implementation.Solid audit
Measured across the six touched production modules against integrated base
762a44b819ee:createEffectcreateRenderEffectuntrackaddEventListenerquerySelector(All)flushThe sole effect is
ui/src/pages/chat/solid-render-lifecycle.ts:124: committed DOM gates imperative layout work and cancellation when a retained pane parks. Effects decrease 83.3%; production decreases 7 lines. Tests add 48 lines for terminal-receipt persistence and direct owner-delivery retirement, including local-only receipt rejection.Evidence
Current head:
f663d675d8f2a74e59ff3f542799ef4df94977da. Full CI: 39172310997.pnpm tsgo:ui, scoped format/lint,git diff --checksrc/auto-reply/reply/reply-admission-ticket.ts,src/auto-reply/reply/reply-turn-admission-owner.tsci:fullsecurity-fastpassed6fcf1c433273: 336,506 B → head1038712f833c: 336,520 B (+14 B), identical 1,019,449 B raw JS and 1 startup CSS request; strict checks passedThe Agents catalog-publication real-Gateway case passes on the current head. Its fixture waits for visible primary selection before beginning the independent fallback gesture; existing post-fallback primary/config/draft assertions remain, without a backend-persistence wait or timeout change. Rendered appearance and styles are unchanged, so the screenshot gate does not apply.
Only performance job
117808026313and aggregate gate117810753367failed. That job's own same-host comparison proves the pre-existing chat-boot excess: base50bb09d7ba13is 1,490,230 B, already above the unchanged 1,490,000 B ceiling; tested merge43964a795474is 1,490,304 B (+74 B), with 25 → 25 requests. Startup remains within budget. The performance-checker source blobs are unchanged in the tested merge.The authorized inherited-failure admission binds the exact failed run, checkout, ordered merge parents, performance output, complete job inventory, inspected delta, and artifact hashes. No test failure is waived, and the aggregate CI run is not claimed green.