opentui: fatal: undefined is not an object (evaluating 'agents()[0].name') #2716

Closed
opened 2026-02-16 17:36:56 -05:00 by yindo · 3 comments
Owner

Originally created by @mschenk42 on GitHub (Nov 9, 2025).

Description

TypeError: undefined is not an object (evaluating 'agents()[0].name')
    at <anonymous> (src/cli/cmd/tui/context/local.tsx:50:27)
    at init (src/cli/cmd/tui/context/local.tsx:47:19)
    at provider (src/cli/cmd/tui/context/helper.tsx:8:26)
    at untrack (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:475:12)
    at runComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:742:22)
    at updateComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:724:3)
    at devComponent (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:593:3)
    at children (src/cli/cmd/tui/context/helper.tsx:18:24)
    at <anonymous> (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:1057:29)
    at runComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:742:22)...

OpenCode version

1.0.50

Steps to reproduce

I am encountering an issue while attempting to connect to a remote OpenCode headless server. However, if I execute the client (rather than attach) on the remote host, the operation is successful. This functionality was previously working, but it has begun to fail today. I suspected that an upgrade issue might be the cause, but I reverted to the previously working release, which is now also failing.

opencode attach http://ssds-meta-store.ai-services.svc.cluster.local:4096

Screenshot and/or share link

Image

Operating System

macOS Sequoia 15.7.1

Terminal

Ghostty 1.2.3

Originally created by @mschenk42 on GitHub (Nov 9, 2025). ### Description ``` TypeError: undefined is not an object (evaluating 'agents()[0].name') at <anonymous> (src/cli/cmd/tui/context/local.tsx:50:27) at init (src/cli/cmd/tui/context/local.tsx:47:19) at provider (src/cli/cmd/tui/context/helper.tsx:8:26) at untrack (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:475:12) at runComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:742:22) at updateComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:724:3) at devComponent (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:593:3) at children (src/cli/cmd/tui/context/helper.tsx:18:24) at <anonymous> (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:1057:29) at runComputation (../../node_modules/.bun/solid-js@1.9.9/node_modules/solid-js/dist/dev.js:742:22)... ``` ### OpenCode version 1.0.50 ### Steps to reproduce I am encountering an issue while attempting to connect to a remote OpenCode headless server. However, if I execute the client (rather than attach) on the remote host, the operation is successful. This functionality was previously working, but it has begun to fail today. I suspected that an upgrade issue might be the cause, but I reverted to the previously working release, which is now also failing. `opencode attach http://ssds-meta-store.ai-services.svc.cluster.local:4096` ### Screenshot and/or share link <img width="1120" height="1011" alt="Image" src="https://github.com/user-attachments/assets/9e01adbe-bc4c-45ce-a782-f5c5afcdc106" /> ### Operating System macOS Sequoia 15.7.1 ### Terminal Ghostty 1.2.3
yindo added the opentuibug labels 2026-02-16 17:36:56 -05:00
yindo closed this issue 2026-02-16 17:36:56 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Nov 9, 2025):

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

  • #4101: Similar "undefined is not an object" error pattern with opentui component crash, both involving evaluation failures in the TUI context
  • #3934: Same error pattern "undefined is not an object (evaluating 'lines().length')" - similar SolidJS stack trace and opentui component crashes
  • #4110, #4108, #4106, #4105, #4104: Recent closed issues with nearly identical "undefined is not an object (evaluating 'local.model.parsed().model')" errors - these were recently resolved and may contain the fix

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

@github-actions[bot] commented on GitHub (Nov 9, 2025): This issue might be a duplicate of existing issues. Please check: - #4101: Similar "undefined is not an object" error pattern with opentui component crash, both involving evaluation failures in the TUI context - #3934: Same error pattern "undefined is not an object (evaluating 'lines().length')" - similar SolidJS stack trace and opentui component crashes - #4110, #4108, #4106, #4105, #4104: Recent closed issues with nearly identical "undefined is not an object (evaluating 'local.model.parsed().model')" errors - these were recently resolved and may contain the fix Feel free to ignore if none of these address your specific case.
Author
Owner

@mschenk42 commented on GitHub (Nov 9, 2025):

I just tried version 1.0.51 and I'm no longer getting the error. I'll keep testing to make sure. Thank you!

@mschenk42 commented on GitHub (Nov 9, 2025): I just tried version 1.0.51 and I'm no longer getting the error. I'll keep testing to make sure. Thank you!
Author
Owner

@thdxr commented on GitHub (Nov 9, 2025):

yep i think i fixed it - sorry about that

@thdxr commented on GitHub (Nov 9, 2025): yep i think i fixed it - sorry about that
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#2716