CursorAndrew Chan & Kevin NguyenExplainer
Keeping the Cursor app stable
Summary
Cursor's desktop app faces disruptive crashes as usage and features such as subagents, instant grep, and browser use have expanded, with most failures caused by out-of-memory conditions. The team measures instability across Electron's multi-process architecture using telemetry, per-session and per-request crash rates, minidumps, stack traces, crash breadcrumbs, and dashboards that update within minutes. Its two-pronged debugging strategy combines feature-level experiments and oversize-message instrumentation with bottom-up analysis based on a crash watcher, Chrome DevTools Protocol (CDP) stacks, automated daily investigations, opt-in heap snapshots, and low-rate allocation profiling. Findings led to chunking large data, killswitches, lifecycle fixes for leaks, and process isolation for extensions, while prevention uses Bugbot rules, stress tests, garbage collection, performance tests, and automated rollbacks. OOM-per-session fell 80% from its late-February peak and OOM-per-request fell 73% since March 1.
Context
Cursor's increasing user base and ambitious features have made stability more difficult, while rare crashes can disrupt users who spend the entire day in the app. Most crashes are caused by the app running out of memory, particularly in renderer processes that can make the editor unusable.
Approach / What changed
The team combines crash telemetry and rapidly updating per-session and per-request metrics with top-down feature experiments, oversize-message instrumentation, breadcrumbs, and bottom-up crash-stack analysis. It also uses opt-in heap snapshots, continuous low-rate allocation profiling, targeted mitigations such as chunking and killswitches, extension process isolation, and regression-prevention tooling.
Takeaways
Crash metrics are broken down by app version and process, with minidumps and stack traces where available; dashboards update within minutes to help detect release regressions.
Acute OOMs are addressed with killswitches or chunked processing for large data, while slow-and-steady OOMs require tracing retainers and correcting long-lived object lifecycles.
Isolating extensions in separate processes limits the impact of one extension's crash or long task on others, but uses slightly more system memory.
Source and freshness
- Source
- cursor.com
- Published
- Added to Yomu
- Last updated
Summaries are generated from the original by a language model. Check the original before relying on it.
Keep reading
Related reading
The Good Stuff
Paid picks we use ourselves. Links carry a referral code — a subscription through one earns us a commission at no extra cost to you.
The best engineering reads, once a week
One useful email. Unsubscribe anytime.