Local-scope plugin records written for git worktrees never update (claude plugin update --scope local ignores the cwd; the records have no auto)
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 52/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
Research direction
The report identifies claude plugin update --scope local, claude plugin list, and records in ~/.claude/plugins/installed_plugins.json; it does not name source files or tests. Start by tracing how the CLI selects local plugin records from the current working directory and how worktree records are created. Done when updating from a worktree updates the record for that worktree or the behavior follows one of the alternatives in the issue, with the reproduced stale version resolved.
Written by the indexing model from the issue text.
Description
Local-scope plugin records written for git worktrees never update (claude plugin update --scope local ignores the cwd; the records have no auto)
Environment: Claude Code 2.1.326, macOS, a plugin from a GitHub marketplace installed with --scope local in a repository's main checkout. The project's .claude/settings.local.json (which enables the plugin) is copied into each new git worktree of that repository.
What happens
- When a session first starts in a git worktree of that repo, Claude Code writes a second local record for the plugin into
~/.claude/plugins/installed_plugins.json, withprojectPath= the worktree, at the version current that day. Unlike the main checkout's record, it has no"auto": true. - Marketplace auto-update later updates the main checkout's record (it has
auto: true), but never the worktree's. - Running
claude plugin update <plugin>@<marketplace> --scope local --jsonfrom inside the worktree does not update the worktree's record either. It answers for the main checkout's record:
while the worktree's record still says{"message":"<plugin> is already at the latest version (1.3.7).","updateOutcome":"up_to_date","oldVersion":"1.3.7","newVersion":"1.3.7"}"version": "1.3.4".claude plugin list --jsonprints the same four records whether run from the worktree or the main checkout.
Resulting installed_plugins.json (paths shortened):
"<plugin>@<marketplace>": [
{ "scope": "local", "projectPath": "/…/repo", "version": "1.3.7", "installPath": "…/cache/<marketplace>/<plugin>/1.3.7", "auto": true, "lastUpdated": "2026-11-17T10:49:58Z" },
{ "scope": "local", "projectPath": "/…/repo-worktrees/x", "version": "1.3.4", "installPath": "…/cache/<marketplace>/<plugin>/1.3.4", "installedAt": "2026-11-17T06:46:18Z", "lastUpdated": "2026-11-17T06:46:18Z" }
]
Expected
Either:
claude plugin update --scope localupdates the local record whoseprojectPathmatches the cwd (or offers a--project <path>option), and records written for worktrees getautolike the one they were derived from; or- a worktree uses the main checkout's local install, without a record of its own.
Impact
Sessions in that worktree keep the plugin version from the day the worktree's first session started, with no supported way to update them short of editing installed_plugins.json. Tooling that checks "is every install current?" after claude plugin update sees the worktree record stay behind and reports the update as failed.
Steps to reproduce
- In a repo,
claude plugin install <plugin>@<marketplace> --scope local. - Copy
.claude/settings.local.jsoninto a newgit worktree add ../wt, startclaudein../wtonce and exit. - Publish a newer plugin version; update the marketplace.
cd ../wt && claude plugin update <plugin>@<marketplace> --scope local --json: it reports the main checkout's version as up to date; the../wtrecord ininstalled_plugins.jsonkeeps the old version and has noauto.
- Dominant language
- TypeScript
- Stars
- 156k
- Forks
- 25k
- Avg merge
- 16h 19m
- Merged PRs (30d)
- 5
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- No contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from anthropics/claude-code
-
area:hooks area:plugins bug has repro platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
anthropics/claude-code#111771 ·
-
area:docs bug documentation
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
anthropics/claude-code#111658 ·
-
area:core bug platform:linux platform:wsl regression
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
anthropics/claude-code#111548 ·
-
area:vscode bug has repro platform:vscode platform:windows
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
anthropics/claude-code#111416 ·
-
area:plugins area:tui bug platform:macos
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
anthropics/claude-code#111195 ·
All issues in anthropics/claude-code
Similar issues
-
chore
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
drydocs/meridian#1503 · 1 comment ·
Maintainers usually reply within 2 days
-
refactor review: high
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
1lck/Lithe-IDEA#2376 ·
Maintainers usually reply within 1 day
-
bug extension mcp
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
primer/primitives#1426 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 88/100
danielmiessler/LifeOS#2941 ·
Maintainers usually reply within 4 days