opencode-copilot-auth error #1547

Open
opened 2026-02-16 17:31:28 -05:00 by yindo · 22 comments
Owner

Originally created by @Lain-droid on GitHub (Aug 31, 2025).

Originally assigned to: @thdxr on GitHub.

INFO 2025-08-31T09:51:23 +323ms service=default version=0.5.29 args=[] opencode
INFO 2025-08-31T09:51:23 +1ms service=app cwd=/root creating
INFO 2025-08-31T09:51:23 +21ms service=app git
INFO 2025-08-31T09:51:23 +40ms service=app name=plugin registering service
INFO 2025-08-31T09:51:23 +2ms service=app name=config registering service
INFO 2025-08-31T09:51:23 +20ms service=config path=/root/.config/opencode/config.json loading
INFO 2025-08-31T09:51:23 +15ms service=config path=/root/.config/opencode/opencode.json loading
INFO 2025-08-31T09:51:23 +1ms service=config path=/root/.config/opencode/opencode.jsonc loading
INFO 2025-08-31T09:51:23 +49ms service=config agent={} mode={} command={} plugin=[] username=root loaded
INFO 2025-08-31T09:51:23 +0ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin
ERROR 2025-08-31T09:51:23 +41ms service=default name=ResolveMessage message=Cannot find module '/root/.cache/opencode/node_modules/opencode-copilot-auth' from '/$bunfs/root/opencode' code=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_modules/opencode-copilot-auth referrer=/$bunfs/root/opencode importKind=import-statement fatal

I tryed to install opencode-copilot-auth with bun but don't worked also I'm tryed reinstall several times it don't work too

Originally created by @Lain-droid on GitHub (Aug 31, 2025). Originally assigned to: @thdxr on GitHub. INFO 2025-08-31T09:51:23 +323ms service=default version=0.5.29 args=[] opencode INFO 2025-08-31T09:51:23 +1ms service=app cwd=/root creating INFO 2025-08-31T09:51:23 +21ms service=app git INFO 2025-08-31T09:51:23 +40ms service=app name=plugin registering service INFO 2025-08-31T09:51:23 +2ms service=app name=config registering service INFO 2025-08-31T09:51:23 +20ms service=config path=/root/.config/opencode/config.json loading INFO 2025-08-31T09:51:23 +15ms service=config path=/root/.config/opencode/opencode.json loading INFO 2025-08-31T09:51:23 +1ms service=config path=/root/.config/opencode/opencode.jsonc loading INFO 2025-08-31T09:51:23 +49ms service=config agent={} mode={} command={} plugin=[] username=root loaded INFO 2025-08-31T09:51:23 +0ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin ERROR 2025-08-31T09:51:23 +41ms service=default name=ResolveMessage message=Cannot find module '/root/.cache/opencode/node_modules/opencode-copilot-auth' from '/$bunfs/root/opencode' code=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_modules/opencode-copilot-auth referrer=/$bunfs/root/opencode importKind=import-statement fatal I tryed to install opencode-copilot-auth with bun but don't worked also I'm tryed reinstall several times it don't work too
Author
Owner

@github-actions[bot] commented on GitHub (Aug 31, 2025):

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

  • #2224: Support for airgapped installation - Similar plugin loading error in Docker environment
  • #735: MacOS 15.5 not running npm i - Same ERR_MODULE_NOT_FOUND pattern, resolved by running npm i in cache directory

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

@github-actions[bot] commented on GitHub (Aug 31, 2025): This issue might be a duplicate of existing issues. Please check: - #2224: Support for airgapped installation - Similar plugin loading error in Docker environment - #735: MacOS 15.5 not running `npm i` - Same ERR_MODULE_NOT_FOUND pattern, resolved by running npm i in cache directory Feel free to ignore if none of these address your specific case.
Author
Owner

@Lain-droid commented on GitHub (Aug 31, 2025):

INFO 2025-08-31T11:30:58 +422ms service=default version=0.5.29 args=[] opencode
INFO 2025-08-31T11:30:58 +2ms service=app cwd=/root creating
INFO 2025-08-31T11:30:58 +13ms service=app git
INFO 2025-08-31T11:30:58 +4ms service=app name=plugin registering service
INFO 2025-08-31T11:30:58 +3ms service=app name=config registering service
INFO 2025-08-31T11:30:58 +6ms service=config path=/root/.config/opencode/config.json loading
INFO 2025-08-31T11:30:58 +2ms service=config path=/root/.config/opencode/opencode.json loading
INFO 2025-08-31T11:30:58 +11ms service=config path=/root/.config/opencode/opencode.jsonc loading
INFO 2025-08-31T11:30:58 +135ms service=config agent={} mode={} command={} plugin=[] username=root loaded
INFO 2025-08-31T11:30:58 +0ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin
INFO 2025-08-31T11:30:58 +1ms service=bun pkg=opencode-copilot-auth version=0.0.2 installing package using Bun's default registry resolution
INFO 2025-08-31T11:30:58 +1ms service=bun cmd=["/root/.opencode/bin/opencode","add","--force","--exact","--cwd","/root/.cache/opencode","opencode-copilot-auth@0.0.2"] cwd=/root/.cache/opencode running
INFO 2025-08-31T11:30:59 +580ms service=bun code=0 stdout=bun add v1.2.19 (aad3abea)

  • opencode-anthropic-auth@0.0.2

installed opencode-copilot-auth@0.0.2

14 packages installed [465.00ms]
stderr=Saved lockfile
done
ERROR 2025-08-31T11:30:59 +20ms service=default name=ResolveMessage message=Cannot find module '/root/.cache/opencode/node_modules/opencode-copilot-auth' from '/$bunfs/root/opencode' code=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_modules/opencode-copilot-auth referrer=/$bunfs/root/opencode importKind=import-statement fatal
root@localhost:~#

@Lain-droid commented on GitHub (Aug 31, 2025): INFO 2025-08-31T11:30:58 +422ms service=default version=0.5.29 args=[] opencode INFO 2025-08-31T11:30:58 +2ms service=app cwd=/root creating INFO 2025-08-31T11:30:58 +13ms service=app git INFO 2025-08-31T11:30:58 +4ms service=app name=plugin registering service INFO 2025-08-31T11:30:58 +3ms service=app name=config registering service INFO 2025-08-31T11:30:58 +6ms service=config path=/root/.config/opencode/config.json loading INFO 2025-08-31T11:30:58 +2ms service=config path=/root/.config/opencode/opencode.json loading INFO 2025-08-31T11:30:58 +11ms service=config path=/root/.config/opencode/opencode.jsonc loading INFO 2025-08-31T11:30:58 +135ms service=config agent={} mode={} command={} plugin=[] username=root loaded INFO 2025-08-31T11:30:58 +0ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin INFO 2025-08-31T11:30:58 +1ms service=bun pkg=opencode-copilot-auth version=0.0.2 installing package using Bun's default registry resolution INFO 2025-08-31T11:30:58 +1ms service=bun cmd=["/root/.opencode/bin/opencode","add","--force","--exact","--cwd","/root/.cache/opencode","opencode-copilot-auth@0.0.2"] cwd=/root/.cache/opencode running INFO 2025-08-31T11:30:59 +580ms service=bun code=0 stdout=bun add v1.2.19 (aad3abea) + opencode-anthropic-auth@0.0.2 installed opencode-copilot-auth@0.0.2 14 packages installed [465.00ms] stderr=Saved lockfile done ERROR 2025-08-31T11:30:59 +20ms service=default name=ResolveMessage message=Cannot find module '/root/.cache/opencode/node_modules/opencode-copilot-auth' from '/$bunfs/root/opencode' code=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_modules/opencode-copilot-auth referrer=/$bunfs/root/opencode importKind=import-statement fatal root@localhost:~#
Author
Owner

@rekram1-node commented on GitHub (Aug 31, 2025):

what happens if you do:

rm -rf ~/.cache/opencode

and then try again

@rekram1-node commented on GitHub (Aug 31, 2025): what happens if you do: rm -rf ~/.cache/opencode and then try again
Author
Owner

@pulpo commented on GitHub (Aug 31, 2025):

@Lain-droid same issue here, in a proot environment under termux...

@pulpo commented on GitHub (Aug 31, 2025): @Lain-droid same issue here, in a proot environment under termux...
Author
Owner

@Lain-droid commented on GitHub (Sep 1, 2025):

Yeah its proot too

@Lain-droid commented on GitHub (Sep 1, 2025): Yeah its proot too
Author
Owner

@pulpo commented on GitHub (Sep 1, 2025):

I tried with the latest version (0.6.0), also deleting the .cache/opencode, an the problem is still present.

@pulpo commented on GitHub (Sep 1, 2025): I tried with the latest version (0.6.0), also deleting the .cache/opencode, an the problem is still present.
Author
Owner

@rekram1-node commented on GitHub (Sep 1, 2025):

I mentioned this to Dax yesterday so I think he is looking into it

@rekram1-node commented on GitHub (Sep 1, 2025): I mentioned this to Dax yesterday so I think he is looking into it
Author
Owner

@HavardPede commented on GitHub (Sep 4, 2025):

Im also encountering this issue, on version 0.6.4

@HavardPede commented on GitHub (Sep 4, 2025): Im also encountering this issue, on version 0.6.4
Author
Owner

@fkukuck commented on GitHub (Sep 8, 2025):

Does this mean you cannot authenticate with GitHub at the moment? Can you confirm? I'm scared to update opencode since I use it with GitHub

@fkukuck commented on GitHub (Sep 8, 2025): Does this mean you cannot authenticate with GitHub at the moment? Can you confirm? I'm scared to update opencode since I use it with GitHub
Author
Owner

@rekram1-node commented on GitHub (Sep 8, 2025):

no it doesnt mean you can’t authenticate it just means occasionally an error will happen and you may have to send a message twice until Dax fixes it, when I say twice I dont mean literally type it out twice itd be more like:

  • send message
  • api error
  • send “.”
    works
@rekram1-node commented on GitHub (Sep 8, 2025): no it doesnt mean you can’t authenticate it just means occasionally an error will happen and you may have to send a message twice until Dax fixes it, when I say twice I dont mean literally type it out twice itd be more like: - send message - api error - send “.” works
Author
Owner

@supastishn commented on GitHub (Sep 13, 2025):

INFO 2025-09-13T19:26:28 +907ms service=default version=0.7.9 args=["auth","login"] opencode INFO 2025-09-13T19:26:28 +1ms service=project directory=/home/supastishn fromDirectory INFO 2025-09-13T19:26:28 +168ms service=models.dev file={} refreshing INFO 2025-09-13T19:26:28 +520ms service=models.dev file
={} refreshing INFO 2025-09-13T19:26:46 +17593ms service=config path=/home/supastishn/.config/opencode/config.json loading INFO 2025-09-13T19:26:46 +2ms service=config path=/home/supastishn/.config/opencode/opencode.json loading INFO 2025-09-13T19:26:46 +2ms service=config path=/home/supastishn/.config/opencode/opencode.jsonc loading INFO 2025-09-13T19:26:46 +123ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin INFO 2025-09-13T19:26:46 +22ms service=bun pkg=opencode-copilot-auth version=0.0.2 installing package using Bun's default registry resolution INFO 2025-09-13T19:26:46 +5ms service=bun cmd=["/home/supastishn/node_modules/opencode-linux-arm64/bin/opencode","add","--force","--exact","--cwd","/home/supastishn/.cache/opencode","opencode-copilot-auth@0.0.2"] cwd=/home/supastishn/.cache/opencode running INFO 2025-09-13T19:26:46 +131ms service=bun code=0 stdout=bun add v1.2.21 (7c45ed97) installed opencode-copilot-auth@0.0.2

1 package installed [51.00ms]
stderr=Saved lockfile
done
ERROR 2025-09-13T19:26:46 +8ms service=default name=Reso
lveMessage message=Cannot find module '/home/supastishn/
.cache/opencode/node_modules/opencode-copilot-auth' from
'/$bunfs/root/index.js' code=ERR_MODULE_NOT_FOUND speci
fier=/home/supastishn/.cache/opencode/node_modules/openc
ode-copilot-auth referrer=/$bunfs/root/index.js importKi
nd=import-statement fatal

im getting the error when i run opencode auth login, even without using github copilot provider. tried deleting cache to no svsil

@supastishn commented on GitHub (Sep 13, 2025): INFO 2025-09-13T19:26:28 +907ms service=default version=0.7.9 args=["auth","login"] opencode INFO 2025-09-13T19:26:28 +1ms service=project directory=/home/supastishn fromDirectory INFO 2025-09-13T19:26:28 +168ms service=models.dev file={} refreshing INFO 2025-09-13T19:26:28 +520ms service=models.dev file ={} refreshing INFO 2025-09-13T19:26:46 +17593ms service=config path=/home/supastishn/.config/opencode/config.json loading INFO 2025-09-13T19:26:46 +2ms service=config path=/home/supastishn/.config/opencode/opencode.json loading INFO 2025-09-13T19:26:46 +2ms service=config path=/home/supastishn/.config/opencode/opencode.jsonc loading INFO 2025-09-13T19:26:46 +123ms service=plugin path=opencode-copilot-auth@0.0.2 loading plugin INFO 2025-09-13T19:26:46 +22ms service=bun pkg=opencode-copilot-auth version=0.0.2 installing package using Bun's default registry resolution INFO 2025-09-13T19:26:46 +5ms service=bun cmd=["/home/supastishn/node_modules/opencode-linux-arm64/bin/opencode","add","--force","--exact","--cwd","/home/supastishn/.cache/opencode","opencode-copilot-auth@0.0.2"] cwd=/home/supastishn/.cache/opencode running INFO 2025-09-13T19:26:46 +131ms service=bun code=0 stdout=bun add v1.2.21 (7c45ed97) installed opencode-copilot-auth@0.0.2 1 package installed [51.00ms] stderr=Saved lockfile done ERROR 2025-09-13T19:26:46 +8ms service=default name=Reso lveMessage message=Cannot find module '/home/supastishn/ .cache/opencode/node_modules/opencode-copilot-auth' from '/$bunfs/root/index.js' code=ERR_MODULE_NOT_FOUND speci fier=/home/supastishn/.cache/opencode/node_modules/openc ode-copilot-auth referrer=/$bunfs/root/index.js importKi nd=import-statement fatal im getting the error when i run opencode auth login, even without using github copilot provider. tried deleting cache to no svsil
Author
Owner

@rekram1-node commented on GitHub (Sep 13, 2025):

@supastishn what do u see if you run:

(cd ~/.cache/opencode && BUN_BE_BUN=1 opencode pm ls)
@rekram1-node commented on GitHub (Sep 13, 2025): @supastishn what do u see if you run: ``` (cd ~/.cache/opencode && BUN_BE_BUN=1 opencode pm ls) ```
Author
Owner

@yungchinghsiao commented on GitHub (Oct 17, 2025):

I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit (https://github.com/oven-sh/bun/issues/1440).

@yungchinghsiao commented on GitHub (Oct 17, 2025): I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit (https://github.com/oven-sh/bun/issues/1440).
Author
Owner

@gabrieldebem commented on GitHub (Oct 20, 2025):

im having a similar error here in my 15.5 macos

~/.cache/opencode > npm i @ai-sdk/anthropic@beta                                                                                                                                                                                                                        took 5s at 11:41:07
⠙(node:68885) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.
(Use `node --trace-warnings ...` to show where the warning was created)

added 7 packages in 17s

1 package is looking for funding
  run `npm fund` for details
~/.cache/opencode > (cd ~/.cache/opencode && BUN_BE_BUN=1 opencode pm ls)                                                                                                                                                                                              took 18s at 11:41:30
[3.92ms] migrated lockfile from package-lock.json
/Users/gabriel.bem/.cache/opencode node_modules (7)
└── @ai-sdk/anthropic@3.0.0-beta.32
~/.cache/opencode > opencode auth login                                                                                                                                                                                                                                         at 11:41:37

┌  Add credential
│
◇  Select provider
│  GitHub Copilot
Error: Unexpected error, check log file at /Users/gabriel.bem/.local/share/opencode/log/2025-10-20T144142.log for more details
~/.cache/opencode > cat /Users/gabriel.bem/.local/share/opencode/log/2025-10-20T144142.log                                                                                                                                                                              took 3s at 11:41:45
INFO  2025-10-20T14:41:42 +70ms service=default version=0.15.8 args=["auth","login"] opencode
INFO  2025-10-20T14:41:42 +0ms service=project directory=/Users/gabriel.bem/.cache/opencode fromDirectory
INFO  2025-10-20T14:41:42 +5ms service=models.dev file={} refreshing
INFO  2025-10-20T14:41:42 +308ms service=models.dev file={} refreshing
INFO  2025-10-20T14:41:43 +1141ms service=config path=/Users/gabriel.bem/.config/opencode/config.json loading
INFO  2025-10-20T14:41:43 +0ms service=config path=/Users/gabriel.bem/.config/opencode/opencode.json loading
INFO  2025-10-20T14:41:43 +1ms service=config path=/Users/gabriel.bem/.config/opencode/opencode.jsonc loading
INFO  2025-10-20T14:41:43 +4ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","@opencode-ai/plugin@0.15.8","--exact"] cwd=/Users/gabriel.bem/.config/opencode running
INFO  2025-10-20T14:41:43 +4ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","@opencode-ai/plugin@0.15.8","--exact"] cwd=/Users/gabriel.bem/.opencode running
INFO  2025-10-20T14:41:43 +2ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin
INFO  2025-10-20T14:41:43 +0ms service=bun pkg=opencode-copilot-auth version=0.0.3 installing package using Bun's default registry resolution
INFO  2025-10-20T14:41:43 +0ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","--force","--exact","--cwd","/Users/gabriel.bem/.cache/opencode","opencode-copilot-auth@0.0.3"] cwd=/Users/gabriel.bem/.cache/opencode running
INFO  2025-10-20T14:41:44 +902ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca)
 stderr=Resolving dependencies
Resolved, downloaded and extracted [1]
error: GET https://npm.pkg.github.com/@opencode-ai%2fplugin - 404
 done
ERROR 2025-10-20T14:41:44 +0ms service=default e=Command failed with exit code 1 rejection
INFO  2025-10-20T14:41:44 +16ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca)
 stderr=[0.16ms] migrated lockfile from package-lock.json
Resolving dependencies
Resolved, downloaded and extracted [1]
error: GET https://npm.pkg.github.com/opencode-copilot-auth - 404
 done
ERROR 2025-10-20T14:41:44 +15ms service=default pkg=opencode-copilot-auth version=0.0.3 name=BunInstallFailedError message=BunInstallFailedError cause=Error: Command failed with exit code 1 stack=BunInstallFailedError: BunInstallFailedError
    at <anonymous> (/$bunfs/root/index.js:68596:43)
    at processTicksAndRejections (native:7:39) fatal
INFO  2025-10-20T14:41:45 +780ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca)
 stderr=Resolving dependencies
Resolved, downloaded and extracted [1]
error: GET https://npm.pkg.github.com/@opencode-ai%2fplugin - 404
 done
ERROR 2025-10-20T14:41:45 +0ms service=default e=Command failed with exit code 1 rejection

I’m getting a similar error on macOS 15.5 — looks like
GET https://npm.pkg.github.com/opencode-copilot-auth
doesn’t exist (404).

@gabrieldebem commented on GitHub (Oct 20, 2025): im having a similar error here in my 15.5 macos ``` ~/.cache/opencode > npm i @ai-sdk/anthropic@beta took 5s at 11:41:07 ⠙(node:68885) Warning: Setting the NODE_TLS_REJECT_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification. (Use `node --trace-warnings ...` to show where the warning was created) added 7 packages in 17s 1 package is looking for funding run `npm fund` for details ~/.cache/opencode > (cd ~/.cache/opencode && BUN_BE_BUN=1 opencode pm ls) took 18s at 11:41:30 [3.92ms] migrated lockfile from package-lock.json /Users/gabriel.bem/.cache/opencode node_modules (7) └── @ai-sdk/anthropic@3.0.0-beta.32 ~/.cache/opencode > opencode auth login at 11:41:37 ┌ Add credential │ ◇ Select provider │ GitHub Copilot Error: Unexpected error, check log file at /Users/gabriel.bem/.local/share/opencode/log/2025-10-20T144142.log for more details ~/.cache/opencode > cat /Users/gabriel.bem/.local/share/opencode/log/2025-10-20T144142.log took 3s at 11:41:45 INFO 2025-10-20T14:41:42 +70ms service=default version=0.15.8 args=["auth","login"] opencode INFO 2025-10-20T14:41:42 +0ms service=project directory=/Users/gabriel.bem/.cache/opencode fromDirectory INFO 2025-10-20T14:41:42 +5ms service=models.dev file={} refreshing INFO 2025-10-20T14:41:42 +308ms service=models.dev file={} refreshing INFO 2025-10-20T14:41:43 +1141ms service=config path=/Users/gabriel.bem/.config/opencode/config.json loading INFO 2025-10-20T14:41:43 +0ms service=config path=/Users/gabriel.bem/.config/opencode/opencode.json loading INFO 2025-10-20T14:41:43 +1ms service=config path=/Users/gabriel.bem/.config/opencode/opencode.jsonc loading INFO 2025-10-20T14:41:43 +4ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","@opencode-ai/plugin@0.15.8","--exact"] cwd=/Users/gabriel.bem/.config/opencode running INFO 2025-10-20T14:41:43 +4ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","@opencode-ai/plugin@0.15.8","--exact"] cwd=/Users/gabriel.bem/.opencode running INFO 2025-10-20T14:41:43 +2ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin INFO 2025-10-20T14:41:43 +0ms service=bun pkg=opencode-copilot-auth version=0.0.3 installing package using Bun's default registry resolution INFO 2025-10-20T14:41:43 +0ms service=bun cmd=["/opt/homebrew/Cellar/opencode/0.15.8/libexec/lib/node_modules/opencode-ai/node_modules/opencode-darwin-arm64/bin/opencode","add","--force","--exact","--cwd","/Users/gabriel.bem/.cache/opencode","opencode-copilot-auth@0.0.3"] cwd=/Users/gabriel.bem/.cache/opencode running INFO 2025-10-20T14:41:44 +902ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) stderr=Resolving dependencies Resolved, downloaded and extracted [1] error: GET https://npm.pkg.github.com/@opencode-ai%2fplugin - 404 done ERROR 2025-10-20T14:41:44 +0ms service=default e=Command failed with exit code 1 rejection INFO 2025-10-20T14:41:44 +16ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) stderr=[0.16ms] migrated lockfile from package-lock.json Resolving dependencies Resolved, downloaded and extracted [1] error: GET https://npm.pkg.github.com/opencode-copilot-auth - 404 done ERROR 2025-10-20T14:41:44 +15ms service=default pkg=opencode-copilot-auth version=0.0.3 name=BunInstallFailedError message=BunInstallFailedError cause=Error: Command failed with exit code 1 stack=BunInstallFailedError: BunInstallFailedError at <anonymous> (/$bunfs/root/index.js:68596:43) at processTicksAndRejections (native:7:39) fatal INFO 2025-10-20T14:41:45 +780ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) stderr=Resolving dependencies Resolved, downloaded and extracted [1] error: GET https://npm.pkg.github.com/@opencode-ai%2fplugin - 404 done ERROR 2025-10-20T14:41:45 +0ms service=default e=Command failed with exit code 1 rejection ``` I’m getting a similar error on macOS 15.5 — looks like GET https://npm.pkg.github.com/opencode-copilot-auth doesn’t exist (404).
Author
Owner

@rekram1-node commented on GitHub (Oct 20, 2025):

@gabrieldebem can you do:

rm -rf ~/.cache/opencode

then run:

opencode run hello --print-logs

@rekram1-node commented on GitHub (Oct 20, 2025): @gabrieldebem can you do: `rm -rf ~/.cache/opencode` then run: `opencode run hello --print-logs`
Author
Owner

@621625 commented on GitHub (Oct 22, 2025):

@gabrieldebem can you do:

rm -rf ~/.cache/opencode

then run:

opencode run hello --print-logs

Hi rekram1-node,

Hope you are well.

Same issue. Your input gives:

[root@localhost ~]# rm -rf ~/.cache/opencode [root@localhost ~]# opencode run hello --print-logs INFO 2025-10-22T08:30:00 +23481ms service=default version=0.1
5.13 args=["run","hello","--print-logs"] opencode INFO 2025-10-22T08:30:00 +5ms service=project directory=/root fromDirectory INFO 2025-10-22T08:30:00 +159ms service=config path=/root/.config/opencode/config.json loading INFO 2025-10-22T08:30:00 +11ms service=config path=/root/.config/opencode/opencode.json loading INFO 2025-10-22T08:30:00 +1ms service=config path=/root/.config/opencode/opencode.jsonc loading INFO 2025-10-22T08:30:00 +23ms service=bun cmd=["/root/.openc
ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact
"] cwd=/root/.config/opencode running
INFO 2025-10-22T08:30:00 +43ms service=bun cmd=["/root/.openc
ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact
"] cwd=/root/.opencode running
INFO 2025-10-22T08:30:00 +58ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) installed @opencode-ai/plugin@0.15.13 Failed to install 1 package
[65.00ms] done
stderr=FileNotFound: failed copying files from cache to desti
nation for package @opencode-ai/sdk Saved lockfile
done ERROR 2025-10-22T08:30:00 +0ms service=default e=Command faile
d with exit code 1 rejection
INFO 2025-10-22T08:30:01 +275ms service=plugin path=opencode-
copilot-auth@0.0.3 loading plugin
INFO 2025-10-22T08:30:01 +11ms service=bun pkg=opencode-copil
ot-auth version=0.0.3 installing package using Bun's default r
egistry resolution
INFO 2025-10-22T08:30:01 +1ms service=bun cmd=["/root/.openc

ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact"] cwd=/root/.opencode running INFO 2025-10-22T08:30:00 +58ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) installed @opencode-ai/plugin@0.15.13

Failed to install 1 package
[65.00ms] done
stderr=FileNotFound: failed copying files from cache to desti
nation for package @opencode-ai/sdk
Saved lockfile done ERROR 2025-10-22T08:30:00 +0ms service=default e=Command failed with exit code 1 rejection INFO 2025-10-22T08:30:01 +275ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin INFO 2025-10-22T08:30:01 +11ms service=bun pkg=opencode-copil
ot-auth version=0.0.3 installing package using Bun's default r
egistry resolution
INFO 2025-10-22T08:30:01 +1ms service=bun cmd=["/root/.openc$de/bin/opencode","add","--force","--exact","--cwd","/root/.cac
he/opencode","opencode-copilot-auth@0.0.3"] cwd=/root/.cache/o
pencode running INFO 2025-10-22T08:30:01 +211ms service=bun code=0 stdout=bun add v1.3.0 (b0a6feca) installed opencode-copilot-auth@0.0.3

1 package installed [82.00ms]
stderr=Saved lockfile
done
ERROR 2025-10-22T08:30:01 +45ms service=default name=ResolveMe
ssage message=Cannot find module '/root/.cache/opencode/node_m
odules/opencode-copilot-auth' from '/$bunfs/root/index.js' cod
e=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_mo
dules/opencode-copilot-auth referrer=/$bunfs/root/index.js imp
ortKind=import-statement fatal
Error: Unexpected error, check log file at for more details

error: Cannot find module '/root/.cache/opencode/node_modules/
opencode-copilot-auth' from '/$bunfs/root/index.js'
INFO 2025-10-22T08:30:01 +587ms service=bun code=0 stdout=bun
add v1.3.0 (b0a6feca)

installed @opencode-ai/plugin@0.15.13

3 packages installed [1154.00ms]
stderr=Saved lockfile
done
[root@localhost ~]#

@621625 commented on GitHub (Oct 22, 2025): > [@gabrieldebem](https://github.com/gabrieldebem) can you do: > > `rm -rf ~/.cache/opencode` > > then run: > > `opencode run hello --print-logs` Hi rekram1-node, Hope you are well. Same issue. Your input gives: [root@localhost ~]# rm -rf ~/.cache/opencode [root@localhost ~]# opencode run hello --print-logs INFO 2025-10-22T08:30:00 +23481ms service=default version=0.1 5.13 args=["run","hello","--print-logs"] opencode INFO 2025-10-22T08:30:00 +5ms service=project directory=/root fromDirectory INFO 2025-10-22T08:30:00 +159ms service=config path=/root/.config/opencode/config.json loading INFO 2025-10-22T08:30:00 +11ms service=config path=/root/.config/opencode/opencode.json loading INFO 2025-10-22T08:30:00 +1ms service=config path=/root/.config/opencode/opencode.jsonc loading INFO 2025-10-22T08:30:00 +23ms service=bun cmd=["/root/.openc ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact "] cwd=/root/.config/opencode running INFO 2025-10-22T08:30:00 +43ms service=bun cmd=["/root/.openc ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact "] cwd=/root/.opencode running INFO 2025-10-22T08:30:00 +58ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) installed @opencode-ai/plugin@0.15.13 Failed to install 1 package [65.00ms] done stderr=FileNotFound: failed copying files from cache to desti nation for package @opencode-ai/sdk Saved lockfile done ERROR 2025-10-22T08:30:00 +0ms service=default e=Command faile d with exit code 1 rejection INFO 2025-10-22T08:30:01 +275ms service=plugin path=opencode- copilot-auth@0.0.3 loading plugin INFO 2025-10-22T08:30:01 +11ms service=bun pkg=opencode-copil ot-auth version=0.0.3 installing package using Bun's default r egistry resolution INFO 2025-10-22T08:30:01 +1ms service=bun cmd=["/root/.openc ode/bin/opencode","add","@opencode-ai/plugin@0.15.13","--exact"] cwd=/root/.opencode running INFO 2025-10-22T08:30:00 +58ms service=bun code=1 stdout=bun add v1.3.0 (b0a6feca) installed @opencode-ai/plugin@0.15.13 Failed to install 1 package [65.00ms] done stderr=FileNotFound: failed copying files from cache to desti nation for package @opencode-ai/sdk Saved lockfile done ERROR 2025-10-22T08:30:00 +0ms service=default e=Command failed with exit code 1 rejection INFO 2025-10-22T08:30:01 +275ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin INFO 2025-10-22T08:30:01 +11ms service=bun pkg=opencode-copil ot-auth version=0.0.3 installing package using Bun's default r egistry resolution INFO 2025-10-22T08:30:01 +1ms service=bun cmd=["/root/.openc$de/bin/opencode","add","--force","--exact","--cwd","/root/.cac he/opencode","opencode-copilot-auth@0.0.3"] cwd=/root/.cache/o pencode running INFO 2025-10-22T08:30:01 +211ms service=bun code=0 stdout=bun add v1.3.0 (b0a6feca) installed opencode-copilot-auth@0.0.3 1 package installed [82.00ms] stderr=Saved lockfile done ERROR 2025-10-22T08:30:01 +45ms service=default name=ResolveMe ssage message=Cannot find module '/root/.cache/opencode/node_m odules/opencode-copilot-auth' from '/$bunfs/root/index.js' cod e=ERR_MODULE_NOT_FOUND specifier=/root/.cache/opencode/node_mo dules/opencode-copilot-auth referrer=/$bunfs/root/index.js imp ortKind=import-statement fatal Error: Unexpected error, check log file at for more details error: Cannot find module '/root/.cache/opencode/node_modules/ opencode-copilot-auth' from '/$bunfs/root/index.js' INFO 2025-10-22T08:30:01 +587ms service=bun code=0 stdout=bun add v1.3.0 (b0a6feca) installed @opencode-ai/plugin@0.15.13 3 packages installed [1154.00ms] stderr=Saved lockfile done [root@localhost ~]#
Author
Owner

@621625 commented on GitHub (Oct 22, 2025):

I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit (oven-sh/bun#1440).

Hello,

Hope you are well.

What is the process to delete everything? I also kind of which there were an uninstall flag or something that uninstalls and purges everything.

@621625 commented on GitHub (Oct 22, 2025): > I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit ([oven-sh/bun#1440](https://github.com/oven-sh/bun/issues/1440)). Hello, Hope you are well. What is the process to delete everything? I also kind of which there were an uninstall flag or something that uninstalls and purges everything.
Author
Owner

@honzakostejn commented on GitHub (Nov 7, 2025):

I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit (oven-sh/bun#1440).

I can confirm this did the trick for me as well.

cd ~/.cache/opencode
rm -rf ./node_modules
npm install
opencode auth login
@honzakostejn commented on GitHub (Nov 7, 2025): > I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit ([oven-sh/bun#1440](https://github.com/oven-sh/bun/issues/1440)). I can confirm this did the trick for me as well. ```bash cd ~/.cache/opencode rm -rf ./node_modules npm install opencode auth login ```
Author
Owner

@ajinkyaT commented on GitHub (Dec 10, 2025):

This did't worked for me. getting same error. On version [v1.0.143]

I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit (oven-sh/bun#1440).

I can confirm this did the trick for me as well.

cd ~/.cache/opencode
rm -rf ./node_modules
npm install
opencode auth login

@ajinkyaT commented on GitHub (Dec 10, 2025): This did't worked for me. getting same error. On version [v1.0.143] > > I just resolved a similar module-not-found error by deleting everything and reinstall using npm. Reinstall using bun from scratch does not resolve the error. I suspect it this might have to do with mixup of npm and bun - but i am not familiar with both so this is a pure speculation. I am behind a coporate proxy and bun's support of proxy does not seem to work consistently (It hangs installing missing modules reported by opencode). I suspect that might be the culprit ([oven-sh/bun#1440](https://github.com/oven-sh/bun/issues/1440)). > > I can confirm this did the trick for me as well. > > cd ~/.cache/opencode > rm -rf ./node_modules > npm install > opencode auth login
Author
Owner

@rekram1-node commented on GitHub (Dec 10, 2025):

@ajinkyaT do you need copilot auth? If not set this env var:
OPENCODE_DISABLE_DEFAULT_PLUGINS=1

@rekram1-node commented on GitHub (Dec 10, 2025): @ajinkyaT do you need copilot auth? If not set this env var: `OPENCODE_DISABLE_DEFAULT_PLUGINS=1`
Author
Owner

@codemuse commented on GitHub (Dec 11, 2025):

I had a similar issue, I wanted to use the new GHE support, but I didn't get to the prompt to input the .ghe.com domain, it would just hang on the bun command as it printed int the logs. I found this in another GH issues and that worked for me:

rm ~/.bun/install/cache -rf 
@codemuse commented on GitHub (Dec 11, 2025): I had a similar issue, I wanted to use the new GHE support, but I didn't get to the prompt to input the .ghe.com domain, it would just hang on the bun command as it printed int the logs. I found this in another GH issues and that worked for me: ``` rm ~/.bun/install/cache -rf ```
Author
Owner

@pbassut commented on GitHub (Dec 30, 2025):

I had a similar issue, I wanted to use the new GHE support, but I didn't get to the prompt to input the .ghe.com domain, it would just hang on the bun command as it printed int the logs. I found this in another GH issues and that worked for me:

rm ~/.bun/install/cache -rf 

Confirming that deleting the bun cache worked for me too.

@pbassut commented on GitHub (Dec 30, 2025): > I had a similar issue, I wanted to use the new GHE support, but I didn't get to the prompt to input the .ghe.com domain, it would just hang on the bun command as it printed int the logs. I found this in another GH issues and that worked for me: > > ``` > rm ~/.bun/install/cache -rf > ``` Confirming that deleting the bun cache worked for me too.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#1547