Repository navigation
fix(tui): restore remembered global sessions - #126135
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
steipete
marked this pull request as ready for review
August 19, 2026 02:41
Contributor
Author
|
Land-ready verification for exact head
|
Contributor
Author
|
Merged via squash.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Aug 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: #126046
What Problem This Solves
Fixes an issue where users who had the special
globalTUI session remembered under per-sender scope would reopen the TUI without--sessionand silently end up inmain. The exact restore lookup excluded the global row, so even after #126046 correctly held startup sends until restore and history settled, the first admitted send still targeted the wrong session.Why This Change Was Made
The remembered-session owner now includes the global row only when the exact remembered key is
global. Ordinary Ctrl+P picker and recent-session list queries continue to exclude global sessions, so this changes only the broken exact restore path and composes with #126046's existing startup admission gate.No protocol, config, storage, dependency, changelog, or release surface changes.
User Impact
Reopening the TUI after using the remembered global session now restores that session before startup becomes ready, so the first send is delivered to
globalinstead of silently falling back tomain. Non-global remembered sessions and the ordinary session picker behave as before.Evidence
Before the fix, the focused real-
runTuifake-backend PTY regression failed 1/1 because the restore request sentincludeGlobal: false, so the backend filtered out the rememberedglobalrow.After the fix:
check:changed, source-blind behavior validation, andgit diff --check: passedThe PTY test drives the real
runTui()loop and verifies the exact restore request plus firstsendChatsession key through the fake backend. It does not prove Gateway transport, embedded backend runtime, provider behavior, session persistence, or live streaming; no real Gateway transport proof was run. No screenshot is included because the defect is the hidden backend session target rather than a rendering change, and the PTY call assertion is the relevant boundary proof.Production LOC: +1/-1 (net 0). Test support: +7/-9 (net -2). Tests: +46/-2 (net +44).
AI-assisted. I reviewed and understand the change. No prompts, transcripts, or session logs are included.