Skip to content

fix(desktop): mitigate Chromium AX renderer crash and harden recovery - #1002

Merged
vastsa merged 1 commit into
mainfrom
fix/ax-crash-workaround
Sep 24, 2026
Merged

vastsa merged 1 commit into
mainfrom
fix/ax-crash-workaround

Conversation

@vastsa

@vastsa vastsa commented Sep 24, 2026

Copy link
Copy Markdown
Owner

Summary

Chromium has a known CHECK failure in AXBlockFlowData::ComputeNeighborOnLine (chromium #552018997, #549525849) that kills the renderer when an AT client reads the accessibility tree while the DOM is mutated — exactly what happens during streaming agent responses.

Short-term: add --disable-renderer-accessibility at startup to prevent the crash trigger for users not relying on screen readers.

Medium-term: add a 2 s crash-loop cooldown to renderer recovery so repeated rapid crashes produce a brief blank instead of a tight reload loop.

Changes

  • index.ts — app.commandLine.appendSwitch("disable-renderer-accessibility") before app.whenReady()
  • renderer-recovery.ts — cooldown logic (first crash reloads immediately, subsequent ones within 2 s are delayed)
  • renderer-recovery.test.mjs — 5 tests (was 3), covering cooldown behavior

Tested

  • node --test apps/desktop/test/renderer-recovery.test.mjs — 5/5 pass
  • tsc --noEmit — clean

Upstream tracking

Chromium has a known CHECK failure in AXBlockFlowData::ComputeNeighborOnLine
(chromium #552018997, #549525849) that kills the renderer when an assistive
technology client reads the accessibility tree while the DOM is being mutated.
This is the exact scenario during streaming agent responses and affects both
Windows and macOS across Electron 41–43 / Chromium 146–152.

Short-term: add --disable-renderer-accessibility at startup to prevent
Chromium from building the in-renderer accessibility tree unless the user
explicitly opts in. This eliminates the crash trigger for users who do not
rely on screen readers.

Medium-term: add a crash-loop cooldown (2 s) to renderer recovery so that
repeated rapid crashes produce a brief blank rather than a tight reload
loop. The first crash still reloads immediately; subsequent crashes within
the cooldown window are delayed.

Upstream tracking:
- https://issues.chromium.org/552018997
- https://issues.chromium.org/549525849
Copilot AI lite review requested due to automatic review settings September 24, 2026 06:49

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@vastsa
vastsa merged commit 8b011cf into main Sep 24, 2026
3 of 4 checks passed

This branch was previously deployed

1 inactive deployment
Preview — 2917aa07 Deployed Sep 24, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants