You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a Codev terminal (architect or builder) shares the editor area with a second editor group and that group is then closed, the terminal pane does not re-render to fill the now-wider pane. Content stays wrapped at the old (~half) column width, the right ~half of the pane is blank, and the visible reflowed text is garbled.
Manual resize (dragging the window edge) or clear-and-reopen recovers. The PTY's COLUMNS is also stuck at the old narrow value, so a running TUI (Claude Code etc.) continues to redraw at the wrong width until the recovery action.
Repro
Open a Codev terminal (e.g. architect) in editor group 1
Open any other editor in group 2 (right side)
Close editor group 2
Observe: the terminal pane is now ~2× wider but content stays at old narrow width; right half blank; visible content garbled
Hypothesis
Same family as the recently-shipped #1052 (terminal rendering corrupted on open: replay painted at not-yet-final width), but a different trigger surface. The on-open path now correctly debounces and flushes at the settled width. Editor-group removal resizes the pane without firing that refit path: the terminal-adapter is not listening on the layout-change event that signals "your sibling group just disappeared, your width just doubled."
Proposed fix (plan-gate)
Wire the right VS Code layout-change signal into the terminal-adapter (exact event API to confirm at plan time, candidates include onDidChangeWindowState and onDidChangeActiveTextEditor plus any group-specific layout event) so editor-group changes trigger:
A SIGWINCH / COLUMNS update propagated to the PTY so the TUI redraws at the right width
Same settled-width discipline as #1052 to avoid an intermediate-size repaint during the layout transition. Symmetric: opening a sibling group (terminal narrows) should hit the same path.
Acceptance criteria
Closing a sibling editor group while a Codev terminal is open triggers a refit; content fills the new pane width
PTY's COLUMNS matches the new pane width so the TUI redraws correctly
Opening a sibling editor group (terminal narrows) also triggers refit, symmetric path
Symptom
When a Codev terminal (architect or builder) shares the editor area with a second editor group and that group is then closed, the terminal pane does not re-render to fill the now-wider pane. Content stays wrapped at the old (~half) column width, the right ~half of the pane is blank, and the visible reflowed text is garbled.
Manual resize (dragging the window edge) or clear-and-reopen recovers. The PTY's
COLUMNSis also stuck at the old narrow value, so a running TUI (Claude Code etc.) continues to redraw at the wrong width until the recovery action.Repro
Hypothesis
Same family as the recently-shipped #1052 (terminal rendering corrupted on open: replay painted at not-yet-final width), but a different trigger surface. The on-open path now correctly debounces and flushes at the settled width. Editor-group removal resizes the pane without firing that refit path: the terminal-adapter is not listening on the layout-change event that signals "your sibling group just disappeared, your width just doubled."
Proposed fix (plan-gate)
Wire the right VS Code layout-change signal into the terminal-adapter (exact event API to confirm at plan time, candidates include
onDidChangeWindowStateandonDidChangeActiveTextEditorplus any group-specific layout event) so editor-group changes trigger:SIGWINCH/COLUMNSupdate propagated to the PTY so the TUI redraws at the right widthSame settled-width discipline as #1052 to avoid an intermediate-size repaint during the layout transition. Symmetric: opening a sibling group (terminal narrows) should hit the same path.
Acceptance criteria
COLUMNSmatches the new pane width so the TUI redraws correctlyProtocol selection
Surfaced by builder pir-1060 while parked at dev-approval; the builder explicitly stayed out of scope on its branch. Recommendation at spawn time:
Out of scope
codev.terminal.repaintOnRefocussetting (orthogonal escape hatch from vscode: terminal renders corrupted and cursor lands at top after window reactivation #1052)Related
Surfaced by
PIR #1060 builder during dev-approval; flagged via inter-agent messaging, kept out of scope on the
builder-pir-1060branch.