plugin list shows project-scoped plugins from other projects; uninstall gives contradictory errors
Bug Description
claude plugin list shows project-scoped plugins that are installed in other projects as if they are installed in the current project. This then causes claude plugin uninstall to give contradictory error messages.
Steps to Reproduce
- Install a plugin at project scope in project A:
claude plugin install superpowers --scope project(from project A directory) - Navigate to a different project B
- Run
claude plugin listfrom project B
Expected: Only plugins installed for project B (or user scope) are shown.
Actual: The plugin from project A appears as project-scoped in the list.
- Try to uninstall it from project B:
claude plugin uninstall superpowers
Error:
✘ Failed to uninstall plugin "superpowers": Plugin "superpowers" is installed in project scope, not user. Use --scope project to uninstall.
- Try again with
--scope project:claude plugin uninstall superpowers --scope project
Error (contradicts the previous error):
✘ Failed to uninstall plugin "superpowers": Plugin "superpowers" is not installed in project scope. Use --scope to specify the correct scope.
Root Cause
The installed_plugins.json stores project-scoped plugins with their projectPath. The plugin list command appears to show all project-scoped entries regardless of whether projectPath matches the current working directory. The uninstall command then inconsistently checks scope — once without filtering by projectPath (finds it), and once with the filter (can't find it for the current project), producing contradictory messages.
installed_plugins.json example
{
"superpowers@claude-plugins-official": [
{
"scope": "project",
"projectPath": "/path/to/project-a",
...
},
{
"scope": "project",
"projectPath": "/path/to/project-b",
...
}
]
}
Running claude plugin list from /path/to/project-c shows superpowers as project-scoped.
Expected Behavior
plugin listshould only show project-scoped plugins whereprojectPathmatches the current working directory (or a parent)plugin uninstallerror messages should be consistent with each other
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗