GeezerVison is showing github.com — Unable to choose models when using opencode attach http://<tailscale-ip>:port · Issue #25826 · anomalyco/opencode
Unable to choose models when using opencode attach http://<tailscale-ip>:port #25826
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff) Description
Description
Although I can perfectly use opencode in this attach session (with the default Big Pickle model), once I try to change models I get the following error (see the end of the issue)
-
I can correctly models both at the "host" computer (via ssh and then manually running opencode) and also from the "attached" computer (via just running opencode normally)
-
In my current setup, the "host" is running NixOS (configuration here if useful) while the "attached" computer is running MacOS Tahoe (26.3) with an M1 chip
TypeError: undefined is not an object (evaluating 'G().length')
at when (/$bunfs/root/src/index.js:886:12786)
at <anonymous> (/$bunfs/root/src/index.js:882:75617)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at i_ (/$bunfs/root/src/index.js:882:63287)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at i (/$bunfs/root/src/index.js:882:58249)
at I0 (/$bunfs/root/src/index.js:882:75663)
at q4 (/$bunfs/root/src/index.js:882:60979)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at v_ (/$bunfs/root/src/index.js:882:62385)
at <anonymous> (/$bunfs/root/src/index.js:886:12760)
at q4 (/$bunfs/root/src/index.js:882:60979)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at v_ (/$bunfs/root/src/index.js:882:62385)
at q4 (/$bunfs/root/src/index.js:882:60979)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at v_ (/$bunfs/root/src/index.js:882:62385)
at <anonymous> (/$bunfs/root/src/index.js:882:119577)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at a8 (/$bunfs/root/src/index.js:882:57794)
at W (/$bunfs/root/src/index.js:882:119564)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at a8 (/$bunfs/root/src/index.js:882:57794)
at f (/$bunfs/root/src/index.js:882:119173)
at <anonymous> (/$bunfs/root/src/index.js:883:132017)
at q4 (/$bunfs/root/src/index.js:882:60979)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at v_ (/$bunfs/root/src/index.js:882:62385)
at <anonymous> (/$bunfs/root/src/index.js:882:75752)
at h_ (/$bunfs/root/src/index.js:882:64605)
at T9 (/$bunfs/root/src/index.js:882:64369)
at nQ (/$bunfs/root/src/index.js:882:66222)
at r_ (/$bunfs/root/src/index.js:882:67177)
at VL0 (/$bunfs/root/src/index.js:882:66517)
at J5 (/$bunfs/root/src/index.js:882:66413)
at K (/$bunfs/root/src/index.js:883:12459)
at replace (/$bunfs/root/src/index.js:883:133350)
at onSelect (/$bunfs/root/src/index.js:994:17337)
at trigger (/$bunfs/root/src/index.js:905:20001)
at a (/$bunfs/root/src/index.js:928:5864)
at onKeyDown (/$bunfs/root/src/index.js:928:7391)
at <anonymous> (/$bunfs/root/src/index.js:936:4249)
at <anonymous> (/$bunfs/root/chunk-2mmvm5jr.js:80:40856)
at emitWithPriority (/$bunfs/root/chunk-2mmvm5jr.js:3:32993)
at processParsedKey (/$bunfs/root/chunk-2mmvm5jr.js:3:32057)
at handleStdinEvent (/$bunfs/root/chunk-2mmvm5jr.js:100:5104)
at <anonymous> (/$bunfs/root/chunk-2mmvm5jr.js:100:4973)
at drain (/$bunfs/root/chunk-2mmvm5jr.js:32:6460)
at drainStdinParser (/$bunfs/root/chunk-2mmvm5jr.js:100:4945)
at <anonymous> (/$bunfs/root/chunk-2mmvm5jr.js:100:2763)
at emit (node:events:95:22)
at addChunk (internal:streams/readable:264:47)
at readableAddChunkPushByteMode (internal:streams/readable:242:18)
at internalRead (native:38:40)
at processTicksAndRejections (native:7:39)...
Plugins
None I believe
OpenCode version
1.14.35
Steps to reproduce
- Configure opencode in home manager via the following
{ config, lib, ... }:
{
programs.opencode = {
enable = true;
# tui.themes = "nord";
};
systemd.user.services.opencode-web = {
Unit = {
Description = "OpenCode Web Service";
After = [ "network.target" ];
};
Service = {
ExecStart = "${lib.getExe config.programs.opencode.package} serve --hostname 0.0.0.0 --port 4096";
WorkingDirectory = "/home/uribo/nixos-config";
Restart = "always";
RestartSec = 5;
# TODO: add EnvironmentFile with sops-nix password
};
Install = {
WantedBy = [ "default.target" ];
};
};
}
-
Ensure both hosts have tailscale running and then attach using `opencode attach http://:4096
-
Attempt to change models via /models
-
Get the error with the screen in the screenshot section
Screenshot and/or share link
Operating System
macOS 26.3 and NixOS (25.11 stable)
Terminal
Ghostty
Activity
kevinher7 commented on May 5, 2026
After reviewing further, this might be due to some PATH issues when running the opencode attach command
added
coreAnything pertaining to core functionality of the application (opencode server stuff) on May 5, 2026kevinher7 commented on May 5, 2026
I was using version 1.1.14 of opencode so I switched to the unstable version of nixpkgs (opencode 1.14.35) since the issue was solved already (+ can use home manager to configure the web server better). I guess the "fixed" version of opencode will be on the stable branch for next release.
AI Summary
"This issue was resolved by updating from opencode 1.1.14 (NixOS stable) to 1.14.19 (NixOS unstable). The upstream fix is in opencode 20675 , which added TTL-based caching for models.dev to prevent redundant fetches on attach clients."
Metadata
Metadata
coreAnything pertaining to core functionality of the application (opencode server stuff) Development
No branches or pull requestsIssue actions