Repository navigation
refactor: render New Session with Solid - #169692
Conversation
Preserve route ownership, draft recovery, and lazy loading while replacing the page, placement pickers, palette controls, and composer renderer. Keep the remaining shared composer seams until the prerequisite lands. Publish pending-create state before preview navigation so a resumed route cannot select an unadmitted session.
Preserve the route, launch controls, draft recovery, attachment flow, and single startup request while replacing the Lit page and controls. Consume the shared native composer controls and retain synchronous domain ownership. Publish pending-create admission before preview navigation and bind delayed dictation sends to their originating draft.
|
🦞👀 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: needs maintainer review before merge. What this changesThis PR ports New Session, its composer, placement pickers, recovery views, and launch controls from Lit to Solid. Example: Open /new at 390×844 with Parity workstation and Agent workspace selected.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep this PR open: the maintainer-directed Solid migration remains necessary on main, no actionable introduced defect was found, and the reviewed head’s CI gate is green. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherThe Control UI turns prompts, attachments, and placement choices into draft-owner operations, Gateway session requests, and startup or recovery views. flowchart TD
A[New Session route] --> B[Solid page and controls]
B --> C[Synchronous draft owners]
C --> D[Gateway browser client]
D --> E[Session admission]
E --> F[Chat or draft recovery]
Technical reviewBest possible solution: Land the Solid cutover with the existing draft, admission, preference, and recovery owners intact. Do we have a high-confidence way to reproduce the issue? This is primarily a renderer migration; source comparison and inspected browser captures establish its scope, and no target code was executed during this read-only review. Is this the best way to solve the issue? The cutover follows the approved Solid direction, removes replaced renderers, and preserves synchronous domain ownership and lazy boundaries. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 799b7a347c50. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfacePR surface statistics unavailable: the file list is incomplete. Review metrics
LabelsLabel changes: No label 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 HistoryReview history (28 earlier review cycles; latest 8 shown)
Reviewed October 12, 2026, 11:54 PM ET / October 13, 2026, 03:54 UTC (Revision 29). |
…-chat-8b # Conflicts: # ui/config/control-ui-boot-modules.json
|
Merged via squash.
|
* refactor(ui): port new session rendering to Solid Preserve route ownership, draft recovery, and lazy loading while replacing the page, placement pickers, palette controls, and composer renderer. Keep the remaining shared composer seams until the prerequisite lands. Publish pending-create state before preview navigation so a resumed route cannot select an unadmitted session. * fix: keep New Session view adapters out of state owners * test: migrate the Skills reader dialog fixture * test: dispose New Session browser fixtures explicitly * fix(ui): preserve New Session tooltip and live status DOM * fix(ui): reuse the Solid folder browser in group defaults * fix(ui): await Gateway challenge before signing browser connect * test(state): verify reclamation reuses readmitted schema proof Expect one successful opening after transient schema invalidation while request authority stays current. Preserve later-invalidation scans and assert fresh transferable proof without an extra reclamation scan. * test(ui): align lifecycle activation with clipped viewports Keep lifecycle activation atomic after Playwright actionability and retain all manual visibility and enabled guards. Extend the exact-once fixture with a partially visible control. Report responsive bounds and sanitized background-work stages without changing assertions or timeouts. * fix(ui): avoid nested Solid render flushes
What Problem This Solves
Port New Session and its launch controls from Lit to Solid while preserving
/new, deep links, host tags, CSS classes, selectors, placement, agent/workspace/template choices, draft recovery, attachments, and the single startup RPC. Solid owns the page, pickers, recovery views, palette controls, and composer. The Lit page class is removed; remaining Lit callers use the registered bridge. Domain owners remain synchronous plain TypeScript, and route/composer/attachment lazy boundaries remain intact.The coupled group-defaults dialog consumes the shared Solid
PlaceBrowser. Pending-create admission is published before preview navigation, and delayed dictation stays bound to its originating draft. Shared components consume the landed prerequisite ports; stateless adapters remain only for unported callers.Coupled repairs and current-main integration
sessions.patch, followed by a retryable schema-admission refusal before the write. Current main now owns the native repair: retire the refused generation and allow one fresh admission before caller entry, preserving authority, cleanup, invalid-receipt, and no-replay boundaries. This PR retains the additional malformed-receipt regression and removes duplicate recovery coverage.Evidence
Current head:
b1d8a22789199c96f3ab060fde1efd0262019a31. Same-machine build baseline:e61083f8f116b50e742a64e219c6a26342e67fcd. The latest repair keeps nested Solid content in its parent rendering transaction using the existing bridge pattern; unowned Lit mounts keep their normal top-level renderer. The original native-titlebar failure reproduces locally before the repair, and all three failed CI cases pass afterward without assertion or timeout changes.b1d8a2278919Earlier unchanged-contract proof includes 201 composer/model/dictation/creation/emoji/mention tests, 18 page/attachment/sidebar tests, 63 route/placement/sibling tests, 68 integration picker/composer tests, and targeted instant-thread/attachment/capability E2Es. Two preceding complete
ci:fullruns passed every UI shard and both real-Gateway shards: 38322192020 and 38328106977. These are historical coverage, not current-head gate evidence.Investigated failures and limits
CI 38339845035 exposed two New Session route-readiness timeouts and an owned-scope write during native-titlebar navigation. Nested top-level Solid rendering in the Lit welcome template could flush queued effects under the parent render owner, halting reactive updates. The shared adapter now follows the bridge’s createRoot/insert ownership pattern and disposes its owned DOM. The existing titlebar case reproduced the same error locally before repair; all three original cases pass afterward. No inherited-failure exception is claimed.
The initial real-Gateway failures were not called inherited: scheduled main passed them. Browser challenge handling and native schema admission were repaired at their owners. Local real-Gateway runs are refused by this host’s managed-Gateway guard; Testbox did not admit a later lease, and the earlier task lease is stopped. Current PR CI 38342548638 supplies passing real-Gateway proof.
Historical local wrapper/group-defaults timeouts and the Bun agent-deletion timeout cascade remain unattributed. Their later passing CI runs are not claimed as causal fixes. No timeout, ownership, or managed-Gateway guard was relaxed. The current local type-aware lint attempts stopped during unrelated plugin-SDK declaration preparation at its existing 300-second guard, before linting the selected files; focused syntax lint and UI types provide local coverage, and the full CI lint gate passed on the current head. No whole-repository local suite or local Docker was used.
Size and screenshots
Production TS/TSX changed-file union against pinned main: 12,231 → 13,217 LOC (+986), 58 files. This counts both sides of renames and excludes tests, declarations, and test support. Explicit JSX/typing, owner/view separation, and the interop needed by remaining Lit callers account for the growth. No dependency or version change was authored.
All captures are inspected and synthetic. The new pair compares unavailable-computer explanations in both selectors at desktop and phone widths. Existing migration and Incognito captures remain below.
Unavailable-computer guidance
The before/after contact sheets are attached at the end. These captures compare main
3c63da22and reviewed Solid integrationb9732086; the guide renderers and CSS are unchanged by the final main merge. They cover the environment picker and command-palette settings on desktop and phone.Retained desktop/mobile parity
These earlier synthetic desktop/mobile pairs were inspected and pixel-identical at their captured baseline and head. The current unavailable-computer comparison covers both selectors at both widths.
Retained Incognito before/after