Repository navigation
fix(terminal): force WebGL repaint after split when dimensions match - #1272
Merged
Merged
Conversation
safeFit() had a dimension-matching optimization that early-returned without calling fitAddon.fit() during pending splits. When the proposed terminal dimensions happened to match the current dimensions (common at certain window sizes), the WebGL canvas was left stale after wrapInSplit() reparented the DOM — producing blank "dead" terminal panes. Now forces fitAddon.fit() + terminal.refresh() when pendingSplitScrollState is set, even when dimensions match. Also: - Add debugLabel (tab/worktree ID) to PaneManager for log correlation - Suppress noisy "no live transport" warning during initial 10s PTY connection grace period - Add headful E2E stress tests exercising the real setup-split flow with WebGL active, forced context loss, and rapid switching Co-authored-by: Orca <help@stably.ai>
The debugLabel field was added to ManagedPaneInternal but the test mock factories were not updated, causing typecheck failures in CI. Co-authored-by: Orca <help@stably.ai>
The orca.yaml added to global-setup.ts caused the worktree.spec.ts "creates a worktree through the composer UI" test to fail — the setup script now fires on every worktree creation, breaking timing assumptions. Scope it to the dead-terminal specs that actually need it. Co-authored-by: Orca <help@stably.ai>
This was referenced Apr 30, 2026
mralexsaavedra
pushed a commit
to mralexsaavedra/orca
that referenced
this pull request
May 2, 2026
…tablyai#1272) Co-authored-by: Orca <help@stably.ai>
enrick-dev
pushed a commit
to enrick-dev/orca
that referenced
this pull request
Oct 15, 2026
…tablyai#1272) Co-authored-by: Orca <help@stably.ai>
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.
Summary
safeFit()had a dimension-matching early-return that skippedfitAddon.fit()during pending splits — leaving the WebGL canvas stale afterwrapInSplit()reparented the DOM. Now forcesfitAddon.fit()+terminal.refresh()whenpendingSplitScrollStateis set, even when dimensions match.debugLabelto PaneManager: Logs now includetab:<id>/wt:<id>so safeFit warnings can be correlated to specific worktrees.@headfultest scenarios exercising the real setup-split flow with WebGL active — basic split, switch-back, rapid multi-worktree switching, forced WebGL context loss, and rapid switching during split lifecycle.Context
The dead terminal bug manifests as blank/unresponsive terminal panes after creating a worktree with a setup split. The PTY is alive (typing accepted), but the WebGL canvas never repaints. Cmd+R fixes it by replaying the daemon snapshot. Console logs show
[terminal] safeFit early-return during pending split for pane 1 — dims 136×89 match current, webgl: trueconfirming the early-return codepath fires in production with WebGL active.Test plan
npx vitest run src/renderer/src/lib/pane-manager(30/30 pass)SKIP_BUILD=1 pnpm run test:e2e:headful(5/5 pass)Made with Orca 🐋