Skip to content

fix(workspaces): reach the phone workspace terminal on desktop - #2004

Merged
mariusvniekerk merged 7 commits into
kenn-io:mainfrom
salmonumbrella:fix/workspace-base-terminal
Nov 19, 2026
Merged

mariusvniekerk merged 7 commits into
kenn-io:mainfrom
salmonumbrella:fix/workspace-base-terminal

Conversation

@salmonumbrella

Copy link
Copy Markdown
Contributor

You can continue work started in your phone's Workspace terminal from the standalone desktop Workspaces view for local workspaces.

Select Workspace to reach the same running claude process, which was previously absent from desktop. Both layouts can stay attached, even while session discovery is pending or unavailable.

Live browser and terminal integration checks have not been run locally.

Closes #1954

Co-authored-by: GPT-6 Astra noreply@openai.com

Model used: GPT-6 Astra

@roborev-ci

roborev-ci Bot commented Nov 14, 2026

Copy link
Copy Markdown

roborev: Combined Review (6d57be1)

Verdict: Changes require fixes for 2 findings.

Medium

  • internal/terminal/handler.go:145-147: If your hidden desktop Workspace tab reconnects while your phone stays attached, the phone’s terminal app resizes to 120×30 until another resize request. The inactive connection applies default dimensions. This affects shared terminals using pty_owner (a terminal backend).

    Fix: Preserve the shared terminal’s size when an inactive client reconnects without dimensions, continue accepting resize requests from visible clients, and add a regression check with two attachments. Where: handler.go, handler_test.go

  • frontend/src/lib/components/terminal/WorkspaceTerminalView.svelte:722-725: After viewing an empty, ready local workspace inside a detail page, opening Settings starts or restarts an unseen shell and prevents idle stopping. The hidden view opens a standalone terminal connection. This affects hosts using pty_owner (a terminal backend).

    Fix: Open new base-terminal connections only in a visible standalone view, while preserving existing connections across navigation. Where: WorkspaceTerminalView.svelte


Reviewers: 3x codex, codex (security), codex (test-value) | Synthesis: codex, 7m18s | Total: 19m3s

@roborev-ci

roborev-ci Bot commented Nov 14, 2026

Copy link
Copy Markdown

roborev: Combined Review (89299e9)

Verdict: No findings at or above medium severity.


Reviewers: 3x codex, codex (security), codex (test-value) | Synthesis: codex, 15s | Total: 11m18s

@roborev-ci

roborev-ci Bot commented Nov 15, 2026

Copy link
Copy Markdown

roborev: Combined Review (bd1e532)

Verdict: No findings at or above medium severity.


Reviewers: 3x codex, codex (security), codex (test-value) | Synthesis: codex, 16s | Total: 11m28s

@mariusvniekerk mariusvniekerk self-assigned this Nov 18, 2026
salmonumbrella and others added 7 commits November 18, 2026 23:57
Offer the same base terminal as a Workspace tab in standalone local
workspaces, including when runtime discovery is pending or unavailable.
Keep launched sessions preferred and preserve saved splits across detail
visits, without adding a runtime session or changing remote workspaces.

Allow concurrent base-terminal attachments while keeping idle-stop
exclusive. Each connection retains ownership of its own transport so a
phone and desktop can share the running process.

Add admission, layout, discovery and cross-device regressions. Local
browser and live terminal integration tests remain unrun.

Refs kenn-io#1954.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
Avoid a workflow-slot teardown error when switching workspaces. Start a
new base terminal only while its workspace is visible, while retaining
an already mounted connection across navigation.

Preserve the shared PTY owner's size when an inactive client attaches
without dimensions. Keep initial size defaults for new tmux clients.
Update existing terminal tests and fixtures for the separate Workspace
tab, retaining their input, clipboard, focus and geometry assertions.

Live browser and terminal integration checks were not run locally.

Refs kenn-io#1954.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
Keep the delayed-details case focused on saved split membership, the
shared base identity, and avoiding a runtime launch. The existing
navigation case covers socket retention across switching and reopening,
including a runtime poll and restored Workspace selection.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
The opt-in Rust owner still rejected a second terminal viewer. Count live attachments so phone and desktop can share input and output without one detach ending the other attachment. Preserve the existing output drain, stop, and post-exit bounds.

The socket-free lifecycle regression reproduced the premature exit and now passes. Rust and Go static checks passed. Socket-backed end-to-end validation remains unverified locally because the environment prohibits those fixtures.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
Require the current base-terminal socket to claim resize before the first phone input and both desktop attachment inputs. Keep the shared process identity, output, and failed runtime discovery assertions unchanged.

The mocked terminal tests and Chromium/Firefox collection passed, as did frontend core checks. Live browser validation remains unverified locally because this environment prohibits browser fixtures.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
Capture the visible slot identity when registering it instead of reading a removed parent session during cleanup. Fix the shared owner and remove the redundant workflow-only null guard.

Update the existing fixtures to use complete terminal settings, retain the base Workspace pane, and observe the base connection heartbeat before input. Keep shared-process and diff-output assertions intact.

The socket-free navigation regression reproduced the null-key exception and now passes. Related unit tests, frontend core checks, collection, and non-mutating lint passed. Live browser validation remains unverified locally because the environment prohibits browser fixtures.

Co-authored-by: GPT-6 Astra <noreply@openai.com>
The shared-terminal test now opens a second websocket on the same
terminal. Main turned the bodyclose lint back on after this branch
started, so that new dial failed lint once the branch was rebased.
Close the handshake response on a failed dial, the same way the other
dials in this file do.

Generated with Claude Code (claude-opus-5-5)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@mariusvniekerk
mariusvniekerk force-pushed the fix/workspace-base-terminal branch from bd1e532 to 8c9af36 Compare November 19, 2026 00:00
@roborev-ci

roborev-ci Bot commented Nov 19, 2026

Copy link
Copy Markdown

roborev: Combined Review (8c9af36)

Verdict: No findings at or above medium severity.


Reviewers: 3x codex, codex (security), codex (test-value) | Synthesis: codex, 15s | Total: 12m11s

@mariusvniekerk
mariusvniekerk added this pull request to the merge queue Nov 19, 2026
Merged via the queue into kenn-io:main with commit 0e74038 Nov 19, 2026
36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

Work started in the mobile "Workspace" terminal is invisible on desktop

2 participants