[BUG] Missing parameter to explicitly specify the current project

Resolved 💬 4 comments Opened Nov 22, 2025 by gw0 Closed Nov 25, 2025

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?

To ensure isolation I am running Claude Code inside a Docker container. I mount the current dir on the host to /workspace inside the container. Unfortunately, now Claude Code treats all projects/directories as a single "workspace" project and consequently mixes sessions/contexts/todos...

The official devcontainer approach has the same issue (mounts to /workspace):

Workaround is to mount current dir in a subdir with same name (e.g. /workspace/my_project):

What Should Happen?

There should be a command line parameter to explicitly specify the current project (e.g. claude --project my_project).

Error Messages/Logs

Steps to Reproduce

Try using either the official devcontainer (https://github.com/anthropics/claude-code/blob/main/.devcontainer/) or my containerized approach (https://github.com/gw0/docker-claude-code) on multiple different projects. Then check ~/.claude/projects or check sessions.

Claude Model

Sonnet (default)

Is this a regression?

No, this never worked

Last Working Version

_No response_

Claude Code Version

2.0.49

Platform

Anthropic API

Operating System

Ubuntu/Debian Linux

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗