Skip to content

[Bug]: Only the last plugin loads in OpenCode 1.1.32 - Multiple plugins not supported #10115

Closed as not planned

Description

@lofibrainwav

Bug Description

When multiple plugins are configured in opencode.json, only the last plugin in the array is loaded. All preceding plugins are silently ignored.

Environment

  • OpenCode Version: 1.1.32
  • OS: macOS Darwin 25.3.0 (Apple Silicon)
  • Installation: /Applications/OpenCode.app

Steps to Reproduce

  1. Configure multiple plugins in ~/.config/opencode/opencode.json:
{
  "plugin": [
    "opencode-wakatime",
    "opencode-discord-notify",
    "opencode-supermemory"
  ]
}
  1. Run opencode debug config

  2. Observe that only the last plugin is loaded:

"plugin": [
  "file:///.../.config/opencode/node_modules/opencode-supermemory/dist/index.js"
]

Test Results

Configuration Expected Actual
[wakatime, discord] Both loaded Only discord
[wakatime, discord, supermemory] All 3 loaded Only supermemory
[antigravity-auth, oh-my-opencode] Both loaded Only oh-my-opencode
[oh-my-opencode, antigravity-auth] Both loaded Only antigravity-auth

Expected Behavior

All plugins in the array should be loaded and functional.

Actual Behavior

Only the last plugin in the array is loaded. Previous plugins are silently filtered out without any error or warning in the logs.

Debug Logs

Running with --print-logs --log-level DEBUG shows no errors - the preceding plugins simply don't appear in plugin loading logs.

Workaround

Currently using only one plugin (oh-my-opencode) as the sole entry.

Additional Context

  • This appears to be a regression - plugins worked previously
  • No error messages are shown - silent failure makes debugging difficult
  • Tested with various plugin combinations (auth plugins, utility plugins) - same behavior

Reported via Claude Code

Activity

  1. github-actions commented on Jan 22, 2026

    @github-actions
    Contributor

    This issue might be a duplicate of existing issues. Please check:

    Feel free to ignore if none of these address your specific case.

  2. cyberprophet commented on Mar 1, 2026

    @cyberprophet
    Contributor

    Opened PR #15598 with a fix that targets the same order-dependent dedup behavior described here (only last plugin survives).\n\nPR: #15598

  3. cyberprophet commented on Mar 1, 2026

    @cyberprophet
    Contributor

    Opened PR #15598 with a fix that targets the same order-dependent plugin dedup behavior described here (only the last plugin survives).

    PR: #15598

  4. cyberprophet commented on Mar 4, 2026

    @cyberprophet
    Contributor

    This is addressed by #15598 which adds node_modules-aware path parsing to getPluginName(). CI is green.

    The root cause is that import.meta.resolve resolves npm plugins to file://…/node_modules/<pkg>/dist/index.js, and then getPluginName() extracts only the filename "index", causing false collisions with any project plugin that also has an index.ts entry point.

    Related issues: #8759, #10115, #11159, #12285, #14304, #15591

  5. github-actions commented on May 4, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

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