/clear and "Clear conversation" create a new empty session instead of clearing the current one

Status Open
Reported on v2.1.246
Maintainer reply None cached
Activity 0 comments · opened Sep 17, 2026

Preflight Checklist

  • [x] I have searched existing issues 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?

Environment:
Claude Code version: 2.1.246 (extension cache also shows 2.1.273 present)
Platform: macOS (darwin-arm64)
Interface: VS Code extension, Session Manager sidebar UI

Expected behavior:
The current session's conversation history is cleared/truncated in place, keeping the same session active with an empty context (so token/context usage actually resets).

What Should Happen?

Actual behavior:
A brand new session is created (new session ID, often inheriting the old session's custom title), while the original session remains fully intact and un-cleared underneath. The new session's .jsonl transcript contains only boilerplate:

Error Messages/Logs

Steps to Reproduce

Steps to reproduce:

Open an existing session with conversation history in the VS Code Claude Code panel
Either type /clear and submit, or select "Clear conversation" from the / command autocomplete panel
Observe the sidebar's session list

Claude Model

Sonnet (default)

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.246

Platform

Other

Operating System

macOS

Terminal/Shell

VS Code integrated terminal

Additional Information

_No response_

View original on GitHub ↗