[Bug]: macOS host + Android: preview doesn't stream to Android until opened on desktop, then isn't interactive from Android #24228
Before submitting#
- I searched existing issues and did not find a duplicate. Related: #23139 (Windows: snapshots and remote viewing stall while T3 is covered), #23015 (Windows unattended: tabs can't be seen from mobile, automation times out), #19420 (iOS: "You have control" but taps never reach the tab).
- I included enough detail to reproduce or investigate the problem.
Area#
apps/mobile (Android remote preview), with apps/desktop as the preview host
Steps to reproduce#
- On a Mac mini running T3 Code (Beta) 0.1.2, run a Claude Code thread. Follow the thread from the Android app over the home network (WireGuard VPN to the LAN).
- Have the agent call
preview_openwithopen: trueon a public page (a canada.ca sign-in page). - On the Android phone, open the thread and tap the preview.
- Open the same preview on the Mac desktop app, then look at it on Android again.
- Try to tap or type in the page from Android.
Expected behavior#
- A tab opened with
open: truestreams to the Android app without anyone opening it on the desktop first. - The person on Android can take control and tap, scroll and type in the page (for example, to enter a password the agent should not type).
Actual behavior#
- The preview doesn't open on Android until it has been opened on the desktop. Android shows "Connecting to browser…" indefinitely. In the same state, every agent
preview_snapshot(with and withoutincludeImage) andpreview_navigatefailed withPreview automation snapshot timed out after 15000ms/Preview automation navigate timed out after 15000ms, even thoughpreview_statusreportedavailable: true, visible: true. A second tab opened withreuseExistingTab: falsebehaved the same. The Mac's display was awake and unlocked, and bringing T3 Code to the front withopen -adid not help. - After restarting the desktop app and opening the preview on the desktop, both work: the agent gets snapshots and Android shows the page.
- Android can't interact with the page. It renders, but taps and typing do nothing, and the user found no way to take control.
preview_statuskept reportingcontrol.owner: "agent"(itsgenerationwent from 0 to 8 while the user was trying).
Impact#
Major degradation or frequent failure
Version or commit#
T3 Code (Beta) desktop 0.1.2; Android app 2.0.0
Environment#
Host: Mac mini, macOS 26.6.2, T3 Code (Beta) 0.1.2. Viewer: Android app 2.0.0 on Android 17, connected over WireGuard to the home LAN. Agent: Claude Code (claude-opus-5-5).
Logs or stack traces#
# server.trace.ndjson, before the desktop app restart (tokens and IPs removed)
PreviewAutomationBroker.awaitResponse durationMs=16003 exit=Failure
PreviewAutomationTimeoutError: Preview automation snapshot timed out after 15000ms.
at PreviewAutomationBroker.awaitResponse (apps/server/dist/binCli-*.mjs:312166)
PreviewAutomationBroker.invoke durationMs=12098 exit=Interrupted
InterruptError: All fibers interrupted without error
at PreviewAutomationBroker.awaitResponse (apps/server/dist/binCli-*.mjs:312170)
# The Android stream request was held ~62 s with no frames:
GET /api/preview-stream/ws?threadId=…&tabId=tab_2_…&maxWidth=364&maxHeight=364&interactive=false durationMs=62452
# Desktop side looked healthy: desktop:preview-register-webview → PreviewManager.registerWebview exit=Success
# After the restart, Android's full-screen view requested (no interactive=false), but taps still had no effect:
GET /api/preview-stream/ws?threadId=…&tabId=tab_1_…&maxWidth=886&maxHeight=1472
Workaround#
None inside T3. We worked around it with our own Chrome instance driven over CDP, plus a small LAN page that streams Page.startScreencast frames to the phone and forwards taps and typing.
Posted by Claude Code (Opus 5.5) on behalf of the account owner.
Correction, added later on 29 October after testing with the host unlocked. Two points in my original comment (kept below) were wrong or untested:
- The missing frames depend on the host's lock state. With the Mac Studio unlocked, shared tabs stream to the MacBook Air normally. Locking the Studio (Ctrl-Cmd-Q) stops the stream, even with Screen Recording granted to T3. This matches
syncPaintingin the desktop bundle: "Electron composites no offscreen guest, so its screenshot or screencast waits for a frame that never comes." A desktop-drawn tab only produces frames while the host window is being composited, and macOS stops compositing when the session is locked. Screen Recording is not involved; in the bundle it is only used by the window snapshot feature. initializeDebugger.defaultBackground … target closed while handling commandis probably not the cause. Indesktop.trace.ndjson, every one of these failures is followed by a successfulPreviewManager.initializeControlSessionin the same second.
With the host unlocked, Take control from the remote client still has no effect. I've added those details to #19420, which tracks that symptom.
Original comment:
Same on a Mac Studio host with a monitor attached, on a newer build: T3 Code (Nightly) 0.1.4-nightly.20261028.3838, which includes #25184. Client: MacBook Air connected over T3 Connect. Server run by the desktop app.
- Shared tabs drawn on the Studio show nothing on the Air for every site, including public pages such as supabase.com.
- Host
server.trace.ndjson:DesktopBrowserChannel.awaitAttachedsucceeds in about 90–100 ms.ServerBrowser.attachViewerthen stays open with no frames; sessions lasted from about 100 seconds to over 2 hours. - Host
desktop.trace.ndjson:PreviewManager.initializeControlSessionfails withinitializeDebugger.defaultBackground, as in the comment above. - Agent
preview_openof supabase.com finished navigating in about 0.8 seconds, thenpreview_snapshotfailed withPreview automation snapshot timed out after 15000ms. - The host's screen was also locked by the screen saver during these failures, and viewer sessions opened while it was locked ended when it was unlocked. We have not compared with an unlocked screen.
- The missing frames depend on the host's lock state. With the Mac Studio unlocked, shared tabs stream to the MacBook Air normally. Locking the Studio (Ctrl-Cmd-Q) stops the stream, even with Screen Recording granted to T3. This matches
Fixed for me in v0.1.6, the latest stable release. A preview tab the agent opens with
preview_opennow shows up and works on my side, and the agent's snapshots and actions on that tab go through. Closing.The locked-host case reported in the comments above wasn't part of this test, so it may need its own issue if it still happens.
muhasaho(GitHub profile, opens in a new tab) closed this
Sign in to join this conversation.
Note
Posted by Claude Code (Opus 5.5) via
t3 triage, on behalf of the account owner.Still happens on 0.1.3 stable with a headless Mac mini host and a macOS desktop client. 0.1.3 already contains the fix from #25184 (
fd71ddc223, which keeps hidden webviews painting while a screencast is pending), so that fix doesn't cover this setup.Setup
Repro
Host traces (server.trace.ndjson)
PreviewManager.open→DesktopBrowserChannel.awaitAttachedsucceeds in 50–80 ms →DesktopBrowserChannel.endpointsucceeds.ServerBrowser.attachViewerthen never completes. In earlier runs that were unblocked over VNC, it completed after 58–119 s.Host traces (desktop.trace.ndjson), around every tab create or recover:
Ruled out on the host
pmset displaysleep 0, pluscaffeinate -ukeeping the display awake during the test.None of these changed the result.
Blurriness (separate from the hang, once a stream does start): desktop-rendered tabs use
renderScale: "display", and theresizeviewer message returns early whentab.desktopis set (ServerBrowser.tsin v0.1.3). So the stream keeps the host pane's size and scale, not the viewer's, which leads to upscaling and letterboxing on a Retina client.Related: #23015, #23139, #22461, #19420.