Skip to content

macOS SnapShot of Microsoft Outlook crashes the accessibility helper with a stack overflow in xa11y #41644

Done

Description

@LRSHRS

What happened

On macOS, every SnapShot taken while Microsoft Outlook is the frontmost window makes macOS show "T3 Code (Beta) quit unexpectedly". The main app keeps running, and the screenshot still reaches the thread, but Outlook's window text is missing. SnapShots of other apps work and include their accessibility text.

Diagnosis

The crashing process is the SnapShot accessibility helper (SnapShotAccessibilityWorker, forked by makeSnapShotAccessibilityProcessPool in apps/desktop/src/snapShot/DesktopSnapShot.ts). It runs from the main app binary, so macOS names the crash after the app.

The crash is a stack overflow in a libuv threadpool thread inside @crowecawcaw/xa11y 0.15.4 while it walks Outlook's accessibility tree:

  • EXC_BAD_ACCESS / KERN_PROTECTION_FAILURE, "Could not determine thread index for stack guard region", Bus error 10
  • Crashing thread: libuv-worker, started from node::ThreadPoolWork::ScheduleWork
  • xa11y.darwin-arm64.node recurses through the same frame (offset 0xdfc0c) into HIServices AXUIElementCopyMultipleAttributeValues → CFStringCreateWithFormat, and the overflow happens there

Outlook's accessibility tree seems to be deep enough to exhaust the libuv worker thread's stack during xa11y's recursive traversal. The helper's isolation works: the capture completes without accessibility context. The user still gets a system crash dialog on every SnapShot of Outlook.

main still pins xa11y 0.15.4, and no SnapShot change since v0.1.11 touches this path, so this is probably not fixed on nightly either.

Possible directions: bound the traversal depth or node count on macOS, run the xa11y read on a thread with a larger stack, or report the deep recursion to xa11y upstream.

Steps to reproduce

  1. On macOS, open Microsoft Outlook and make it the frontmost window, with a message open.
  2. Press the SnapShot shortcut (here: both Shift keys).
  3. The screenshot arrives in T3 Code, and a few seconds later macOS shows "T3 Code (Beta) quit unexpectedly".

The user reports it happens every time with Outlook and not with the other apps they've tried.

Version

T3 Code Desktop 0.1.11 (stable), where the bug happened. The triage CLI and local server are also 0.1.11.

Environment

  • macOS 27.2.1 (26B131), Apple silicon (darwin arm64)
  • T3 Code (Beta) desktop app, local server running inside the desktop app
  • Surface: desktop app, SnapShot global shortcut

Evidence

Four crash reports today (13:14, 13:15, 21:05, 21:06 local), all with the same crashing-thread stack:

Exception: EXC_BAD_ACCESS (SIGILL), KERN_PROTECTION_FAILURE
           "Could not determine thread index for stack guard region"
Termination: Bus error: 10
Thread: libuv-worker (crashed)
  Electron Framework  v8::internal::ThreadIsolation::JitPageReference::AllocationContaining  (symbolication approximate)
  Electron Framework  v8::internal::compiler::CompilationDependencies::PrepareInstall      (symbolication approximate)
  CoreFoundation      __CFStrAllocateMutableContents
  CoreFoundation      __CFStringChangeSizeMultiple
  CoreFoundation      __CFStringAppendBytes
  CoreFoundation      __CFStringAppendFormatCore
  CoreFoundation      CFStringCreateWithFormat
  HIServices          AXUIElementCopyMultipleAttributeValues
  xa11y.darwin-arm64.node  +0x164150
  xa11y.darwin-arm64.node  +0x135264
  xa11y.darwin-arm64.node  +0x134d5c
  xa11y.darwin-arm64.node  +0x15a458
  xa11y.darwin-arm64.node  +0x13f8c0
  xa11y.darwin-arm64.node  +0xdfae0
  xa11y.darwin-arm64.node  +0xdfc0c   (x6, recursion)
  xa11y.darwin-arm64.node  +0x9eb8
  Electron Framework  node::ThreadPoolWork::ScheduleWork()::lambda(uv_work_s*)
  libsystem_pthread   _pthread_start

The desktop trace for the 21:05 capture shows the capture succeeding while the helper crashed:

20:05:53.797Z desktop.snapShot.shortcutActivated  3262 ms  Success
20:05:53.797Z desktop.snapShot.capture            3262 ms  Success
20:05:54.255Z desktop.snapShot.persistCapture     2803 ms  Success
20:05:57.059Z dispatchSnapShotEvent "ready"
(crash report written 20:05:59Z)

A screenshot of the macOS crash dialog will be attached.

Related issues

Fix applied or workaround

None applied. The only workaround is to avoid SnapShot while Outlook is frontmost. There is no setting to turn off accessibility text for SnapShots.

Filed by

Diagnosed and written by Claude Opus 5.5 (claude-opus-5-5) in Claude Code, via the T3 Code triage playbook.

Activity

  1. added
    via-triage
    on Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    via-triage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions