Comprehensive Memory Leak Sweep Across Long Sessions
Claude Code v2.1.69 delivers a sweeping set of memory leak fixes targeting long-running interactive sessions, multi-agent workflows, and SDK consumers. Anthropic addressed over a dozen distinct memory retention bugs — including React Compiler cache accumulation, unbounded hook event queues, and teammate conversation histories lingering after compaction — reducing memory growth substantially during extended use.
Sources & Mentions
5 external resources covering this update
Memory leak: Claude Code process grows to 93 GB heap allocation · Issue #22188
GitHub
BUG: Memory leak in long-running idle Claude Code sessions · Issue #18859
GitHub
Claude Code v2.1.69 Release Notes
GitHub
Claude Code by Anthropic - Release Notes - March 2026 Latest Updates
Releasebot
Claude Code v2.1.69 Release Notes - 103 Changes
claudeupdates.dev
Memory Leak Elimination in Long-Running Sessions
Claude Code v2.1.69 represents one of the most focused memory hygiene releases in the tool's history. Anthropic identified and resolved more than a dozen discrete memory leak sources that had been quietly accumulating RAM during extended sessions, particularly affecting power users, agentic pipelines, and SDK consumers.
React Runtime and REPL Leaks
Two foundational rendering-layer leaks were fixed in this release. The first involved old message array versions accumulating in the React Compiler memoCache over long sessions — each turn was retaining references to prior render states rather than allowing garbage collection. The second affected REPL render scopes, which were accumulating over long sessions at a measured rate of approximately 35MB per 1,000 turns. Both fixes reduce the steady-state memory footprint of interactive sessions significantly.
Hook Events and Interactive Mode
In interactive mode, hook events were accumulating unboundedly during long sessions, with no mechanism to release old event references. This has been corrected so hook event memory is properly freed after processing.
Multi-Agent and Teammate Memory
For users running agent teams, memory retention in in-process teammates was a significant issue: the parent conversation's full history was pinned for the lifetime of each teammate, preventing garbage collection even after /clear or auto-compact operations. This has been fixed, allowing teammate memory to be properly reclaimed when tasks complete. A separate fix addressed a leak in long-running SDK and CCR sessions where conversation messages were retained unnecessarily.
Session Upload and File Operation Improvements
Anthropic improved session upload and memory sync to avoid reading large files into memory before performing size and binary checks — previously, files were loaded in full before being evaluated, causing avoidable memory spikes. File operation performance was also improved by avoiding file content reads for simple existence checks across six code sites.
Long Session Stability
The cumulative effect of these fixes is meaningfully improved stability for extended Claude Code sessions. Developers who keep sessions open for hours, run large multi-agent pipelines, or build on the SDK should observe reduced memory growth over time.