You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
TUI not rendering LLM response in tmux (opentui rendering bug, v1.2.21) #16566
OpenCode TUI stops rendering after submitting a prompt when running inside tmux. The backend completes the LLM response successfully, but the TUI never updates to display it. The UI stays stuck showing ▣ Build · big-pickle indefinitely.
This appears to be the same issue as #5094 (which was closed), but it still reproduces on v1.2.21.
Key findings
Backend completes normally — logs show session.idle and exiting loop within seconds
TUI never re-renders — the response is in the database but not displayed
opencode run works perfectly — same prompt, same tmux pane, response renders fine
Only TUI mode is affected — the opentui rendering layer fails to trigger a redraw
Log evidence
INFO service=session.prompt step=1 sessionID=ses_xxx loop
INFO service=session.prompt sessionID=ses_xxx exiting loop
INFO service=session.prompt sessionID=ses_xxx cancel
INFO service=bus type=session.status publishing
INFO service=bus type=session.idle publishing
Backend finished, but TUI still shows spinner.
Environment
OpenCode version: 1.2.21
OS: Debian (Linux 5.x, x86_64)
Terminal: tmux 3.2a (via ttyd WebSocket proxy)
TERM:tmux-256color (also tested with screen, same result)
tmux settings tested:focus-events on, escape-time 10, default-terminal tmux-256color
This issue might be a duplicate of existing issues. Please check:
TUI broken in tmux after 1.2.17 (found root cause) #16351: TUI broken in tmux after 1.2.17 — very similar symptoms (TUI rendering fails in tmux, same version range, same component), with a root cause identified and a workaround mentioned.
Plugins tested: oh-my-opencode, and also with no plugins at all — same result
Key findings
Backend completes normally — logs show full message.part.delta streaming, exiting loop, then cancel (cleanup)
TUI never renders the response — UI shows ▣ Build · gpt-5.2 but body stays blank, Context shows 0 tokens, 0% used, $0.00 spent
Response exists in DB — verified via sqlite3:
sqlite3 ~/.local/share/opencode/opencode.db "SELECT substr(data, 1, 300) FROM part WHERE message_id = '...';"
Returns full response with type: "text" content.
Share link renders correctly — shared session shows the response in browser
Desktop app works fine — same config, same model, response renders properly
Not model-specific — tested with OpenAI (gpt-5.2, variant none/high) and Google (gemini-3.1-pro-preview) — all same behavior
Not plugin-related — reproduced with "plugin": [] in opencode.json
Issue exists since first install — never worked in TUI on this machine
Log evidence
INFO service=llm providerID=openai modelID=gpt-5.2 agent=build mode=primary stream
INFO service=bus type=message.part.delta publishing ← hundreds of deltas
INFO service=session.prompt step=1 sessionID=ses_xxx loop
INFO service=session.prompt sessionID=ses_xxx exiting loop
INFO service=session.prompt sessionID=ses_xxx cancel
INFO service=bus type=session.idle publishing
DB proof
{"type":"text","text":"Hey — what are you working on today? If you share a repo path or goal (bug, feature, refactor, tests), I'll take it from there."}
Conclusion
This is not tmux-specific. The opentui rendering layer fails to display streamed responses on macOS across multiple terminal emulators. The backend + DB + share links all work correctly — only the TUI rendering is broken.
Reacted by Tyler, Tino Marques, Jan Drlý, Justin and Bjarne Schindler
I can't seem to be able to reproduce the issue of responses not being rendered. Can anyone with that issue check the console? ctrl+p + "Toggle Console", are there any errors?
I can't seem to be able to reproduce the issue of responses not being rendered. Can anyone with that issue check the console? ctrl+p + "Toggle Console", are there any errors?
I do have the same error with the latest opencode build but the console isn't updated neither after I send the prompt, so it does not show any errors.
When running opencode --print-logs and entering a promt, this error shows:
Activity
github-actions commentedon Mar 8, 2026
This issue might be a duplicate of existing issues. Please check:
kimnamwook1 commentedon Mar 8, 2026
Same issue on macOS — native Terminal.app (no tmux)
Reproducing the exact same behavior on macOS (Darwin 25.3.0) with OpenCode v1.2.21, but without tmux — running directly in Terminal.app and iTerm2.
Environment
~/.opencode/bin/opencode)openai/gpt-5.2,google/gemini-3.1-pro-preview,google/gemini-3-pro-previewKey findings
message.part.deltastreaming,exiting loop, thencancel(cleanup)▣ Build · gpt-5.2but body stays blank, Context shows0 tokens, 0% used, $0.00 spenttype: "text"content."plugin": []in opencode.jsonLog evidence
DB proof
{"type":"text","text":"Hey — what are you working on today? If you share a repo path or goal (bug, feature, refactor, tests), I'll take it from there."}Conclusion
This is not tmux-specific. The opentui rendering layer fails to display streamed responses on macOS across multiple terminal emulators. The backend + DB + share links all work correctly — only the TUI rendering is broken.
kommander commentedon Mar 8, 2026
I can't seem to be able to reproduce the issue of responses not being rendered. Can anyone with that issue check the console?
ctrl+p+ "Toggle Console", are there any errors?xybschin commentedon Mar 26, 2026
I do have the same error with the latest opencode build but the console isn't updated neither after I send the prompt, so it does not show any errors.
When running
opencode --print-logsand entering a promt, this error shows:dancoto commentedon Mar 27, 2026
I am seeing the same issue in version 1.3.3.
xybschin commentedon Apr 15, 2026
For me, this is no longer an issue with 1,4.6.