pingdotgg / pingdotgg/t3code

SnapShot shortcut cannot capture Xcode Device Hub on macOS 27

Open
#12,103 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

accepted bug via-triage
Dominant language
TypeScript
Stars
23k
Forks
5.9k
Avg merge
11h 14m
Merged PRs (30d)
357

Description

What happened

On macOS 27, with a simulator open in Xcode's Device Hub, invoking the configured T3 Code SnapShot shortcut consistently fails with “Snapshot failed — The active window is not available for capture.” The reporter supplied a screenshot of the error.

Diagnosis

The desktop trace records DesktopSnapShotError during desktop.snapShot.prepareCapture, before macOS capture starts. In the installed revision, captureSource throws window-unavailable when activeWindow() returns no window. The macOS lookup takes NSWorkspace.frontmostApplication.processIdentifier and searches the on-screen CoreGraphics window list for a layer-0 window with that owner PID.

A read-only OS probe while Device Hub was frontmost returned Device Hub with PID -1 from NSWorkspace, while CoreGraphics listed its visible layer-0 window under PID 35409. That PID belonged to Xcode's DeviceHub executable. The mismatched PIDs explain why the lookup returns no window. The cause of macOS reporting PID -1 for Device Hub has not been determined.

Steps to reproduce

  1. Open a simulator in Xcode 27's Device Hub on macOS 27.
  2. Bring Device Hub to the foreground and invoke the configured T3 Code SnapShot shortcut.
  3. Observe “Snapshot failed — The active window is not available for capture.” The reporter says this happens consistently.

Version

T3 Code Nightly 0.0.43-nightly.20260916.1811 (ccf220be205f0e509021dbc8cbda90daa638e20d).

Environment

macOS 27.0 (build 26A428), Apple Silicon (arm64); Xcode 27.0 (build 27A266a); T3 Code desktop app. The t3 triage CLI ran under Node v26.8.2.

Evidence

2026-09-16 10:52:50 -05:00  desktop.snapShot.prepareCapture  Failure
DesktopSnapShotError: The active window is not available for capture.
  at captureSource (.../apps/desktop/dist-electron/main.cjs:97112:23)

NSWorkspace frontmost application: Device Hub, PID -1
CoreGraphics on-screen layer-0 window: Device Hub, owner PID 35409
PID 35409 executable: /Applications/Xcode.app/Contents/Applications/DeviceHub.app/Contents/MacOS/DeviceHub

Related issues

No matching issue found. #11713 also mentions Device Hub but concerns simulator installation detection, not SnapShot capture.

Fix applied or workaround

No T3 Code fix applied. A manual macOS window screenshot can be attached to the T3 Code composer as a workaround.

Filed by

Codex (Astra) via t3 triage.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at desktop.snapShot.prepareCapture and inspect captureSource and activeWindow in apps/desktop/dist-electron/main.cjs, where the trace shows the failure. Reproduce with Xcode Device Hub frontmost and compare the NSWorkspace PID with the CoreGraphics owner PID. Done means the configured SnapShot shortcut captures Device Hub instead of reporting that the active window is unavailable.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, typescript
Domain
desktop, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.