Full Byte Developer.

Check five Claude Code compaction and sandbox fixes

Review the 2.1.309 and 2.1.311 fixes for long sessions, stale instructions, MCP tools and sandbox behavior.

Published · 3 sources

Claude Code releases 2.1.309 and 2.1.311 fix several failures that can look like a model ignoring instructions or getting stuck. Our WEEKLY post covers these October releases [1][2].

Check the installed version

bash
claude --version

If your installation supports Claude Code's updater, run [3]:

bash
claude update
claude --version

For a package-manager installation, use that manager's update instructions in the setup documentation. Confirm the version after updating; these fixes first appeared in the releases below.

Four session fixes in 2.1.311

  • Standard-context sessions that crossed 200K tokens could stop with a usage-credit error. The fix makes them compact and continue.
  • Edits to CLAUDE.md and MEMORY.md could be stale immediately after automatic compaction. The release fixes that stale view.
  • Subagents could miss MCP tools when the server finished connecting after the subagent started. The release fixes that timing problem.
  • A very long list item in CLAUDE.md could cause long freezes during startup or file work. The release fixes those freezes [1].

Compaction still summarizes context. Keep instructions concise and check the actual file when a response appears to use an old rule.

Sandbox fixes in 2.1.309

The earlier release fixes shell startup files running outside the sandbox before sandboxed Bash commands on macOS and Linux. It also prevents sandboxed commands and auto-accepted edits from modifying the file supplied through --mcp-config [2].

These are specific fixes. Keep your existing sandbox and permission settings enabled after updating. If you were working around one of these bugs, retry the original task with the updated client and record the version alongside the result.

Keep this guide

By Full Byte Developer

Original posts: Instagram post, Facebook post, Threads post, TikTok photos

Filed under Claude Code, Security

Sources

Next in this stack