OpenCode

How to troubleshoot OpenCode BunInstallFailedError

Separate optional plugin downloads from the core OpenCode Provider configuration first.

Start with these checks

An optional plugin cannot download its model data.

  • Plugin installation or startup reports BunInstallFailedError or a models.dev network error.
  • DNS or network access failed
  • Check network and DNS in the current terminal
BunInstallFailedErrormodels.dev

01

Confirm the failure is in the plugin layer

When the error names BunInstallFailedError or models.dev, first check whether core OpenCode starts.

02

Check network and terminal environment

Check DNS, proxy, and Bun/npm access, then compare behavior with the plugin disabled.

  1. 1Check network and DNS in the current terminal
  2. 2Confirm the proxy applies to this process

03

Confirm recovery and prevent recurrence

The plugin downloads successfully and core OpenCode still works; keep a minimal plugin-free config for future diagnosis.

  1. 1Confirm the proxy applies to this process
  2. 2Temporarily disable the plugin and test core OpenCode

If it is still not fixed

Sources

Reconfigure

Return to the integration center and continue the setup steps.

Return to the related setup step