anthropics / anthropics/claude-code

[BUG] Design window renderer grows unbounded during generation and is killed at 2-4GB (macOS, Apple Silicon)

未关闭
#93,679 12 条评论 1 个 reaction 已指派 0 人 在 GitHub 查看
area:desktop bug has repro perf:memory platform:macos
主要语言
Python
星标
145k
派生
23.1k
PR 合并指标
PR 指标待抓取

描述

### Preflight Checklist

- [x] I have searched [existing issues](https://github.com/anthropics/claude-code/issues?q=is%3Aissue%20state%3Aopen%20label%3Abug) and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code

### What's Wrong?

### What's Wrong?

The Design window goes blank mid-generation. The renderer process for
that window grows to several GB over roughly a minute, then is killed by
the OS. The window is left blank with no content and no way to reload it
(Cmd+R only affects the chat window). On reopening Design, the session
shows "We got interrupted — the work paused before finishing" with
Resume/Dismiss.

This is NOT the known GPU-compositing or post-update-cache blank screen.
gpu-info.json shows the GPU healthy and active (ANGLE Metal, Apple M4,
active: true, init 143ms). No GPU process crash is logged.

### Evidence

Four occurrences in ~20 minutes, from [process-memory] samples in
main.log. Each shows a renderer climbing then disappearing, with system
free memory jumping at the moment it dies:

- renderer 18247: 258MB (10:25) -> 2241MB (10:26) -> 2081MB (10:27) ->
gone (10:28), sys_free 1.8GB -> 6.6GB
- renderer 22414: 254MB (10:34) -> 2329MB (10:35) -> gone (10:38),
sys_free -> 7.0GB
- renderer 22767: 4219MB (10:39) -> gone (10:40)
- renderer 23052: 644MB (10:43) -> 4037MB (10:44) -> gone (10:45),
tree_rss 6548MB -> 1885MB, sys_free -> 7.4GB

Two peaked at ~4.0GB (4037MB, 4219MB), suggesting a hard per-renderer
ceiling. The two that died near 2.2GB appear to be system memory
pressure instead — sys_free_raw sits at 66-120MB for long stretches and
there is an explicit "trigger=pressure" sample at 10:12:40.

The 10:45 memory sample is missing entirely, i.e. the sampler itself
could not be scheduled.

### Crash handling

The only trace is an empty Sentry capture at the moment of death:

[error] Sentry caught: {
eventId: '...',
type: 'Unknown',
value: 'No message',
stack: undefined
}

No message, no stack — consistent with the process being killed
externally rather than throwing. There is no "renderer gone" log line
and no error boundary or reload affordance in the UI.

### Possible contributing factor

A live preview server (local dev server, port 3000) was running in the
same session. At 10:43:17: "[Preview] Server did not become ready within
timeout". Renderer 23052 first appears 5 seconds later at 644MB and
quadruples within the minute. Unclear whether the ballooning process is
the Design canvas or the live preview pane — worth checking both.

### What Should Happen

1. The renderer should not grow unbounded during generation.
2. If it is killed, the failure should be caught and surfaced, not left
as a silent blank window.
3. The Design window should have a reload path (Cmd+R, or a reload
button in the error state).

### Steps to Reproduce

1. On a 16GB Apple Silicon Mac, open Claude Desktop and use it for a
while so baseline memory reaches ~4-5GB across ~40 child processes.
2. Open Design and ask for a substantial generation (in my case,
reading a markdown file and producing design output).
3. Watch ~/Library/Logs/Claude/main.log [process-memory] samples.
4. The Design renderer climbs past 2GB; the window blanks when it is
killed.

### Environment

- App version: [FILL IN — Claude menu > About Claude]
- macOS: [FILL IN — Apple menu > About This Mac]
- Hardware: MacBook Air, Apple M4, 16GB unified memory
- GPU: ANGLE Metal Renderer, driver 26.3.1, active: true
- Is this a regression? Unknown

### Additional Information

Workarounds found so far: restart the app before Design sessions to
lower the memory floor, close the live preview pane, and keep each turn
small. None of these are fixes — the renderer still grows, it just has
more room before it hits the ceiling.

### What Should Happen?

The design console shouldn't go blank.

### Error Messages/Logs

```shell

```

### Steps to Reproduce

it happens every time I use the design console.

### Claude Model

None

### Is this a regression?

Yes, this worked in a previous version

### Last Working Version

_No response_

### Claude Code Version

Claude 1.52386.0 (1003ca) 2026-09-10T05:55:17.000Z

### Platform

Anthropic API

### Operating System

macOS

### Terminal/Shell

Terminal.app (macOS)

### Additional Information

_No response_

贡献指南

这个仓库没有索引到贡献指南

调研方向

Start by reproducing the Design-window failure while monitoring ~/Library/Logs/Claude/main.log [process-memory] samples and gpu-info.json. Compare the Design canvas with the live preview pane, then trace whichever renderer is growing. Done means generation no longer causes unbounded renderer growth, and a killed renderer produces a visible recovery or reload path instead of a blank window.

由索引模型根据 Issue 内容生成。

评估

技术栈
macos
领域
desktop, performance
Issue 类型
缺陷
难度
5/5
预计耗时
一周以上
活跃度
活跃
描述清晰度
需要澄清
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。