Follow Discord
Sweep 22 Oct 2026 · 04:32Z Build v2.1.308 527 read Stable v2.1.308 Latest v2.1.308 Next v2.1.308 Feeds RSS JSON llms.txt llms-full.txt Unofficial

Claude Code v2.1.290 ·

Worktree removal checks the checkout first, and worktree errors are reworded

Claude Code now checks a git worktree before deleting it, and worktree error messages name fewer paths and suggest a different --worktree name

Group of 5 You'll notice Improvements
JSON All of v2.1.290
You'll noticeTier: how much it should matter to you
2Useful: my rating, 1 to 5
1Signal: worth watching, 1 to 5
WorktreesArea: what it touches
ImprovementsKind: in v2.1.290,
ImprovementsSection of the release

What

A git worktree is a second working folder for the same repository. Claude Code creates one when you start it with --worktree, and agents can get their own. This release changes how worktrees are removed and how worktree problems are reported.

  • Removal now first calls a new remover that checks the checkout before deleting anything. It only falls back to git worktree remove --force when the outcome is "unanchored". Before, it went straight to git worktree remove --force.
  • The remover reports one of four outcomes: removed, not_registered, refused or unanchored. A failed result carries the state of the checkout, and the check on the repository's git folder and root happens earlier.
  • Agent worktree removal goes through the same remover. New messages include "refused before anything was deleted" and "its .git file is missing or does not point to git's record of it".
  • An error about a worktree that belongs to a different repository no longer names the repositories.
  • Cleanup can now drop the registration of a stopped entry (dropIfStopped, deregisterIfStopped). The fallback log line now reads "falling back to removing the git worktree at" instead of "falling back to git worktree remove for".
  • When the branch is already checked out in another worktree, the error no longer names that worktree's path. It now says the branch "is already checked out elsewhere in this repository. Pass a different --worktree name."
  • The "already exists" error and other creation failures now include git's own error message.
  • Removal advice no longer gives ready-made rm -rf or git worktree remove commands with paths in them.
  • The warning about a redirected checkout now names ~/.claude/skills.
  • When a worktree name collides, a new message says "The worktree registration for ... was left in place; pass a different --worktree name."

Why

Because the checkout is checked before anything is deleted, a removal that is refused leaves your files untouched. Cleanup of worktrees for stopped sessions may also remove more than before. When creating a worktree fails, the usual fix is now to pick a different --worktree name. The messages no longer hand you exact paths or commands to delete folders, so you get less path-specific guidance than before.

Read from
Names in the bundle--worktree
Since it was published

The entry above is what we published on the day. These lines were added later, as Anthropic's own pages caught up, and they sit beside the original rather than replacing it.

Added since A small documentation edit on Run parallel sessions with worktrees touched a line naming --worktree after this was published. All of these apply whether you create the worktree with `--worktree` or with `git worktree add`. worktrees see the edit
Confirmed since Anthropic's documentation has since written up --worktree, on Hooks reference. * You exit a `--worktree` session and choose to remove the worktree hooks see the edit
How sure we are
One source agreesOne thing we can check says the same as this entry.
Anthropic's documentation agreesAnthropic's documentation has since written up --worktree, on Hooks reference.

See this entry in the whole of v2.1.290 →

Feedback