Repository navigation
fix: prefill generated session titles when renaming - #139796
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: needs maintainer review before merge. Reviewed September 6, 2026, 2:07 AM ET / 06:07 UTC. ClawSweeper reviewWhat this changesPrefills generated dashboard titles across session rename controls while preserving automatic naming, custom-label clearing, and cancellation when the connection changes. Merge readiness✅ Ready for maintainer review This remains a useful, focused fix: current main still opens empty rename fields outside the chat header. No actionable correctness or security findings were identified, and the previous review contains no outstanding concrete findings. Priority: P2 Review scores
Verification
How this fits togetherThe Control UI turns Gateway session metadata into sidebar, chat-header, and Sessions-page names. Rename controls submit custom labels through the existing session mutation API. flowchart TD
A[Gateway session metadata] --> B[Editable name selection]
B --> C[Sidebar and Sessions dialog]
B --> D[Chat header editor]
C --> E{Name changed?}
D --> E
E -->|No| F[Keep automatic naming]
E -->|Yes| G[Check connection and session identity]
G --> H[Save custom label or clear it]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +25, Tests +69, Docs 0. Total +94 across 11 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Use one editable-name policy across all three controls while retaining the existing label storage, authorization, and session-identity contracts. Do we have a high-confidence way to reproduce the issue? Yes, from source: open sidebar or Sessions-page Rename for a dashboard session with a generated title and no custom label; current main seeds an empty string. This review did not execute the UI. Is this the best way to solve the issue? Yes. Sharing the existing header policy fixes the inconsistent controls without introducing competing naming rules or changing stored-label semantics. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against f3f1995be7fe. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (2 earlier review cycles)
|
|
The remaining review note is a reviewer access limitation, not an identified code defect. I inspected both synthetic before/after captures locally, reproduced the empty sidebar and Sessions-page fields on the original code, and verified the repaired flow in Chrome against a disposable local Gateway fixture: prefilled generated title, keyboard editing, Enter submission, and updated sidebar title. The built-Control-UI browser suite also passed all 9 focused scenarios, including cancellation, no-op saves, clearing, disconnects, and replacement-session protection. Another 142 focused tests and changed checks passed; independent review found no actionable P0–P2 findings. The PR description now includes the live verification and retains the screenshots. The shared-title policy is the requested mitigation and is already implemented. Landing remains subject to the exact-head required CI gates. |
Use the shared editable-title policy in the sidebar, Sessions page, and chat header. Preserve unchanged generated names, custom-label clearing, account decorations, and original connection/session ownership. Cover real keyboard edits and the full rename lifecycle across all three surfaces.
f5fb51e to
5689bdb
Compare
|
Merged via squash.
|
Use the shared editable-title policy in the sidebar, Sessions page, and chat header. Preserve unchanged generated names, custom-label clearing, account decorations, and original connection/session ownership. Cover real keyboard edits and the full rename lifecycle across all three surfaces.
What Problem This Solves
Fixes an issue where users renaming an automatically titled dashboard session from the sidebar or Sessions page would see an empty field even though the session already had a visible title. The chat header already handled these titles, leaving the three rename entry points inconsistent. Related: #129529.
Why This Change Was Made
A shared policy selects the editable custom label or generated dashboard title and detects unchanged submissions. The sidebar's existing lazy operations module owns the dialog and save together; the sidebar and Sessions page capture their original connection before opening the dialog. Durable session identity checks remain intact.
User Impact
Generated dashboard titles are prefilled and editable across all three surfaces. Saving an unchanged title preserves automatic naming; clearing a custom label restores it. Channel/account decorations remain display-only. Connection changes cancel stale edits instead of submitting them through a replacement connection.
Evidence