anthropics / anthropics/claude-code

VS Code: Clicking sidebar session doesn't switch to existing tab, overwrites current view

Open
#94,979 0 comments 0 reactions 0 assignees View on GitHub
area:ide bug platform:macos platform:vscode
Dominant language
Python
Stars
145k
Forks
23.1k
PR merge metrics
PR metrics pending

Description

## Bug Description

When multiple sessions are open as tabs in the Claude Code VS Code extension, clicking a different session in the left sidebar does NOT switch to the corresponding tab. Instead, it tries to overwrite the currently active tab's content, which fails and snaps back.

## Steps to Reproduce

1. Open multiple Claude Code sessions (they appear as tabs at the top)
2. Click on a different session in the left sidebar (SESSION MANAGER)
3. Observe: instead of switching to that session's existing tab, the extension tries to change the current tab's content

## Expected Behavior

Clicking a session in the sidebar should activate/focus its corresponding tab (like how VS Code file explorer works with already-open files).

## Actual Behavior

The extension appears to try to load the clicked session into the currently active tab, briefly flickers, then reverts. The user cannot switch sessions via the sidebar at all when multiple tabs are open.

## Environment

- Claude Code VS Code Extension
- macOS (Darwin 25.6.0)
- Model: Opus 4.6

## Impact

This makes session management very frustrating. Users cannot continue previous threads because clicking them in the sidebar doesn't work. The only workaround is clicking the tab directly at the top, but that requires knowing which tab corresponds to which session.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the behavior with multiple Claude Code sessions open as tabs, then inspect the VS Code extension's SESSION MANAGER sidebar click flow and how it identifies existing session tabs. Done means clicking a sidebar session focuses its existing tab without overwriting, flickering, or reverting the current view.

Written by the indexing model from the issue text.

Assessment

Tech stack
vscode
Domain
developer-experience
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.