Plugin 'Update now' fails when CWD differs from original install workspace

Resolved 💬 5 comments Opened Apr 9, 2026 by ensell-yes Closed Apr 18, 2026

Bug

When a project-scoped plugin is installed from a local marketplace source, ~/.claude/plugins/installed_plugins.json records projectPath as the CWD at install time. The "Update now" action validates the current CWD against this stored projectPath, failing from any other workspace — even the workspace that contains the marketplace source.

Steps to reproduce

  1. Define a custom marketplace with a local plugin source ("source": "./claude-plugin" in .claude-plugin/marketplace.json)
  2. Register the marketplace in global settings via extraKnownMarketplaces
  3. Open Claude Code in workspace A and install the plugin — installed_plugins.json records "projectPath": "/path/to/workspace-A"
  4. Open Claude Code in workspace B (where the marketplace source actually lives)
  5. Navigate to Plugins > [plugin] > "Update now"

Expected

Update succeeds — the plugin is enabled and the source is resolvable.

Actual

Failed to update: Plugin "X" is not installed at scope project (/path/to/workspace-B)

The error names the current CWD, not the registered projectPath. The update fails because CWD ≠ stored projectPath.

Root cause

In installed_plugins.json, the projectPath field for project-scoped plugins is set to the CWD at install time:

"my-plugin@my-marketplace": [{
  "scope": "project",
  "projectPath": "/path/to/workspace-A",
  ...
}]

The "Update now" validation checks projectPath against the current CWD and rejects the update if they differ.

Suggested fix

One or more of:

  • Set projectPath to the directory containing the marketplace source (.claude-plugin/marketplace.json), not the CWD at install time
  • Allow "Update now" from any workspace where the plugin is enabled in enabledPlugins
  • If the plugin is also enabled at user scope in global settings, allow the update regardless of CWD

Workaround

Manually edit ~/.claude/plugins/installed_plugins.json and change projectPath to the directory you want to update from.

Environment

  • Claude Code v2.1.96
  • macOS (Darwin 25.3.0)

View original on GitHub ↗

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