anthropics / anthropics/claude-code

[BUG] Cache expiry warning shown in VS Code extension but not in terminal CLI on --resume

Đang mở
#94,456 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
area:tui bug platform:vscode platform:windows
Ngôn ngữ chính
Python
Star
145k
Fork
23.1k
Chỉ số merge pull request
Chỉ số pull request đang chờ

Mô tả

### 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?

When resuming a session that has been idle for days, the VS Code extension shows a warning like Idle 3d 7h. The prompt cache has likely expired, so your next message will re-cache about 594k tokens.

The same session resumed from the terminal with claude --resume shows no such warning.

Environment

CLI: 2.1.272 (Windows, PowerShell)
VS Code extension: anthropic.claude-code 2.1.270
Plan: Max subscription

### What Should Happen?

Expected: the warning should appear in both clients, since the cache state is a property of the session, not the client.

### Error Messages/Logs

```shell

```

### Steps to Reproduce

Leave a session with large context idle for several days
Open the workspace in VS Code — warning appears
Run claude --resume in PowerShell, select the same session — no warning

Expected: the warning appears in both clients, since the cache state is a property of the session, not the client

### Claude Model

Opus

### Is this a regression?

I don't know

### Last Working Version

_No response_

### Claude Code Version

2.1.272

### Platform

Anthropic API

### Operating System

Windows

### Terminal/Shell

PowerShell

### Additional Information

_No response_

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.