[BUG] installed_plugins.json not updated when project marketplace plugin version chnages

Resolved 💬 4 comments Opened Apr 5, 2026 by syntax-x404 Closed May 26, 2026

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?

When a plugin installed from a project-local marketplace (.claude/marketplaces/) has its version bumped in the project source (e.g., updating version in .claude-plugin/plugin.json from 1.1.1 to 1.1.2), the next Claude Code session correctly:

  1. Detects the version change in the project marketplace source
  2. Creates a new versioned directory in the plugin cache (~/.claude/plugins/cache/<marketplace>/<plugin>/<new-version>/)
  3. Loads the new version into the session (skills show the updated version)

However, ~/.claude/plugins/installed_plugins.json is not updated — it continues to show the old version.

What Should Happen?

Expected behavior

installed_plugins.json should reflect the currently loaded/cached version after a marketplace plugin version change is detected at startup.

Actual behavior

installed_plugins.json retains the version from the original /plugin install and is never updated by the startup marketplace-sync flow.

Error Messages/Logs

Steps to Reproduce

  1. Install a plugin from a project-local marketplace via /plugin install
  2. Confirm installed_plugins.json shows the correct version (e.g., 1.1.1)
  3. Update the plugin's version in the project marketplace source (.claude-plugin/plugin.json to 1.1.2)
  4. Start a new Claude Code session in the same project
  5. Observe: cache has new 1.1.2/ directory, session loads 1.1.2, but installed_plugins.json still shows 1.1.1

Claude Model

None

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.81

Platform

Anthropic API

Operating System

Other Linux

Terminal/Shell

Xterm

Additional Information

Root cause (from source analysis)

The plugin system has two separate code paths:

  • Explicit install (/plugin install): Calls the registry update functions that write to installed_plugins.json
  • Marketplace startup loading: Syncs files to cache and loads plugins, but does not call the registry update functions

The initialization migration function (zyA) that syncs installed_plugins.json with settings.json also doesn't help — when a plugin already exists in the registry, it only checks/updates scope and projectPath, never comparing or updating the version field.

Impact

  • installed_plugins.json becomes stale and unreliable as a source of truth for installed plugin versions
  • Any tooling or diagnostics relying on installed_plugins.json for version info will report incorrect versions
  • Multiple stale cache directories accumulate (old versions are not cleaned up since the registry doesn't know about the new version)

View original on GitHub ↗

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