res-console: terminal state not restored on exit — mouse tracking leaks #5

Open
opened 2026-10-19 15:05:26 +00:00 by muse-lantern · 0 comments
Member

Bug

Exiting res-console (after running TUI mode displays, e.g. res-theme inside res-console + Alt+A menu) does not properly restore terminal state. Mouse movement events keep spamming text into the terminal after res-console closes. The reset command does not clear it.

Expected

On exit, res-console must disable mouse tracking (and any other terminal modes it enabled) so the shell returns to a clean state.

Notes

Appears finicky — reproduced specifically by running res-theme within res-console then using the Alt+A menu.

Found

2026-10-19, testing via wsl.exe.

Update 2026-10-19

Broader pattern confirmed: full TUI apps running under res-console are generally wonky (rendering glitches, state leaks). The mouse-tracking leak above is one symptom. res-console needs a proper child-TUI containment strategy — save/restore full terminal state around child app execution.

## Bug Exiting res-console (after running TUI mode displays, e.g. res-theme inside res-console + Alt+A menu) does not properly restore terminal state. Mouse movement events keep spamming text into the terminal after res-console closes. The `reset` command does not clear it. ## Expected On exit, res-console must disable mouse tracking (and any other terminal modes it enabled) so the shell returns to a clean state. ## Notes Appears finicky — reproduced specifically by running res-theme within res-console then using the Alt+A menu. ## Found 2026-10-19, testing via `wsl.exe`. ## Update 2026-10-19 Broader pattern confirmed: full TUI apps running under res-console are generally wonky (rendering glitches, state leaks). The mouse-tracking leak above is one symptom. res-console needs a proper child-TUI containment strategy — save/restore full terminal state around child app execution.
Sign in to join this conversation.
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
residual/core#5
No description provided.