claude-code - 💡(How to fix) Fix Interface switching should not destroy conversation context [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#55026Fetched 2026-05-01 05:48:09
View on GitHub
Comments
0
Participants
1
Timeline
2
Reactions
0
Participants
Timeline (top)
labeled ×2
RAW_BUFFERClick to expand / collapse

Switching between views/interfaces in Claude Code destroys conversation context. This breaks a fundamental UX convention held by virtually every other application ever built: interface state and data state are separate concerns.

In Slack, switching channels doesn't delete your DMs. In a browser, switching tabs doesn't erase your history. In VS Code itself, switching files doesn't close your other files. Claude Code conflates "where you're looking" with "what exists" — and users shouldn't have to understand the underlying architecture to use the tool.

The fix is obvious: unified conversation history, filtered by context depending on which view you're in. The data doesn't change, the lens does. This is how every mature product handles it.

A concrete example that happened while filing this issue:

The gh CLI is installed and authenticated on this machine. The Claude Code session running inside VS Code knew that — it operates within the user's full shell environment. The Claude.ai app session, used to draft this issue, had no idea gh existed and failed to post it.

Same machine. Same user. Same tools installed. Completely blind to each other.

This isn't just about conversation history — it's a broader environment isolation problem. Two Claude Code surfaces running simultaneously on the same machine share no shell environment, no installed tools, no credentials, no PATH. Every session starts from scratch.

The result: users cannot build a coherent workflow across surfaces. The tool that knows your codebase doesn't know your shell. The tool that knows your shell doesn't know your conversation. You are constantly context-switching between isolated islands, manually carrying state in your head that the tool could trivially share.

The fix isn't complicated in principle: a shared environment layer that all Claude Code surfaces can read from — shell context, installed tools, active credentials. The conversation window can remain isolated. The environment should not be.

This isn't a v1 rough edge — it's a design principle being violated at scale. Users shouldn't feel the architecture.

extent analysis

TL;DR

Implement a unified conversation history and a shared environment layer to separate interface state from data state, allowing Claude Code surfaces to access shared context and tools.

Guidance

  • Introduce a shared environment layer that stores shell context, installed tools, and active credentials, accessible by all Claude Code surfaces.
  • Filter conversation history by context depending on the current view, rather than deleting or isolating it.
  • Ensure that the conversation window remains isolated while allowing access to the shared environment layer.
  • Consider implementing a mechanism to synchronize state between Claude Code surfaces, enabling a coherent workflow across surfaces.

Example

No code snippet is provided as the issue focuses on design principles and architecture rather than specific implementation details.

Notes

The proposed solution requires a fundamental change in the architecture of Claude Code, separating interface state from data state and introducing a shared environment layer. This may involve significant development and testing efforts.

Recommendation

Apply a workaround by implementing a shared environment layer, as this addresses the root cause of the issue and aligns with established UX conventions.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING