Skip to content

Support loading directory-marketplace plugins from their local source #457

Closed

Description

@HuliLulu46

Problem

Plugins installed from a local directory marketplace can resolve to different content in Claude Code and pi-code. On my machine, claude plugin list reported version 0.45.0 with Read from: <local source directory>, while pi-code still discovered skills from the 0.30.0 cached installation.

This is easy to miss when switching between Claude Code and Pi: the active Pi session was missing newly added skills, even though Claude Code reported the updated source version. Inspection of the install record and loader code showed that pi-code selected the old cache. Based on that resolution logic, /reload alone would not sync the source into the cache; I did not separately test a pre-update /reload.

Observed setup and behavior

The marketplace is registered in ~/.claude/plugins/known_marketplaces.json as a local directory (paths and names below are generic examples):

{
  "my-marketplace": {
    "source": {
      "source": "directory",
      "path": "/path/to/local-plugin"
    },
    "installLocation": "/path/to/local-plugin"
  }
}

The marketplace's plugin entry uses "source": "./". The plugin is installed at user scope and enabled.

After the source advanced to 0.45.0, installed_plugins.json still recorded version 0.30.0 and an installPath under plugins/cache/.../0.30.0. Claude Code reported 0.45.0 from the source directory. A skill added in the new source was missing from the active Pi session, and an existing skill's cached body differed from the source. Inspection of pi-code's loader code and the install record established the old cache as the selected path; I did not call pluginSkills() before updating. The direct pluginSkills() verification below was performed after the cache update.

Steps to reproduce

  1. Create/register a local directory marketplace containing a plugin with skills:
    claude plugin marketplace add /path/to/local-plugin
    claude plugin install my-plugin@my-marketplace
  2. Load the enabled plugin through pi-code.
  3. Update the local plugin source, including its version and a new or changed skill, without running claude plugin update.
  4. Compare claude plugin list with pi-code's discovered plugin root/skill paths after /reload.
  5. In the observed setup, Claude Code reports the source version and source directory, while pi-code continues to use the installation recorded in the cache.

Expected behavior / request

Could pi-code support using the current local source for plugins installed from directory marketplaces, so local source changes become available after /reload, consistently with the Claude Code behavior observed above?

The desired outcome is to avoid an extra cache-sync step when developing or using local plugins across both clients. I am leaving the resolution strategy, opt-in/default behavior, and any fallback rules to the maintainers; this request does not assume that all plugins should bypass their installed cache.

Verified workaround

Running the following updated the installed cache and registration from 0.30.0 to 0.45.0:

claude plugin update my-plugin@my-marketplace --scope user

After that update, a fresh call to pi-code's pluginSkills() discovered all 17 skills from the new cache, including the previously missing skill. The checked skill body matched the source by SHA-256. The active Pi session still needs /reload to refresh its command registrations.

Relevant implementation and environment

The behavior is documented in docs/plugins.md. I also checked upstream main at Commit(c7ff779): readInstallIndex() and versionDir() still select the recorded cache installation. I am filing this as an enhancement rather than claiming the current behavior violates the documented contract.

  • pi-code: local checkout reporting 1.7.0, on a local integration branch with unrelated uncommitted skill changes; not a clean released-build reproduction. The cache resolution code relevant to this request was also checked against upstream main as noted above.
  • Pi: 1.5.2
  • Claude Code: 2.1.325
  • Node.js: 24.20.0
  • macOS: 26.6.2

Activity

  1. added a commit that references this issue on Nov 20, 2026
    298c625
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions