TUI stuck forever #1853

Open
opened 2026-02-16 17:32:56 -05:00 by yindo · 10 comments
Owner

Originally created by @eminemead on GitHub (Sep 27, 2025).

Originally assigned to: @rekram1-node on GitHub.

when I run:

opencode run hello --print-logs --log-level DEBUG

I always get stuck:

INFO 2025-09-27T08:20:10 +55ms service=default version=0.12.1 args=["run","hello","--print-logs","--log-level","DEBUG"] opencode
INFO 2025-09-27T08:20:10 +0ms service=project directory=/Users/xiaofei.yin fromDirectory
INFO 2025-09-27T08:20:10 +127ms service=config path=/Users/xiaofei.yin/.config/opencode/config.json loading
INFO 2025-09-27T08:20:10 +1ms service=config path=/Users/xiaofei.yin/.config/opencode/opencode.json loading
INFO 2025-09-27T08:20:10 +0ms service=config path=/Users/xiaofei.yin/.config/opencode/opencode.jsonc loading
INFO 2025-09-27T08:20:10 +1ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin
INFO 2025-09-27T08:20:10 +3ms service=plugin path=opencode-anthropic-auth@0.0.2 loading plugin
INFO 2025-09-27T08:20:10 +29ms service=bus type=* subscribing
INFO 2025-09-27T08:20:10 +0ms service=bus type=session.updated subscribing
INFO 2025-09-27T08:20:10 +0ms service=bus type=message.updated subscribing
INFO 2025-09-27T08:20:10 +0ms service=bus type=message.part.updated subscribing
INFO 2025-09-27T08:20:10 +0ms service=format init
INFO 2025-09-27T08:20:10 +0ms service=bus type=file.edited subscribing
INFO 2025-09-27T08:20:10 +1ms service=session id=ses_675bde9a3ffeh8pMDwrhrYA09p version=0.12.1 projectID=26072424ee3750becfd7240c09e7a038ed2f7ff8 directory=/Users/xiaofei.yin title=New session - 2025-09-27T08:20:10.972Z time={"created":1758961210972,"updated":1758961210972} created
INFO 2025-09-27T08:20:10 +0ms service=lsp serverIds=typescript, vue, eslint, gopls, ruby-lsp, pyright, elixir-ls, zls, csharp, rust, clangd, svelte, jdtls enabled LSP servers
INFO 2025-09-27T08:20:10 +1ms service=bus type=session.updated publishing
INFO 2025-09-27T08:20:10 +2ms service=bus type=message.part.updated subscribing
INFO 2025-09-27T08:20:10 +0ms service=bus type=session.error subscribing
INFO 2025-09-27T08:20:10 +1ms service=session.prompt session=ses_675bde9a3ffeh8pMDwrhrYA09p prompt
INFO 2025-09-27T08:20:10 +4ms service=bus type=message.updated publishing
INFO 2025-09-27T08:20:10 +0ms service=bus type=message.part.updated publishing
INFO 2025-09-27T08:20:10 +1ms service=bus type=session.updated publishing
INFO 2025-09-27T08:20:10 +2ms service=models.dev file={} refreshing
INFO 2025-09-27T08:20:10 +1ms service=provider init
INFO 2025-09-27T08:20:10 +1ms service=provider providerID=openrouter found
INFO 2025-09-27T08:20:10 +0ms service=provider providerID=opencode found
INFO 2025-09-27T08:20:10 +0ms service=provider providerID=opencode modelID=code-supernova getModel
INFO 2025-09-27T08:20:10 +0ms service=provider status=started providerID=opencode getSDK
INFO 2025-09-27T08:20:11 +61ms service=provider status=completed duration=61 providerID=opencode getSDK
INFO 2025-09-27T08:20:11 +0ms service=provider providerID=opencode modelID=code-supernova found
INFO 2025-09-27T08:20:11 +0ms service=session.prompt session=ses_675bde9a3ffeh8pMDwrhrYA09p sessionID=ses_675bde9a3ffeh8pMDwrhrYA09p locking

any idea?

Originally created by @eminemead on GitHub (Sep 27, 2025). Originally assigned to: @rekram1-node on GitHub. when I run: opencode run hello --print-logs --log-level DEBUG I always get stuck: INFO 2025-09-27T08:20:10 +55ms service=default version=0.12.1 args=["run","hello","--print-logs","--log-level","DEBUG"] opencode INFO 2025-09-27T08:20:10 +0ms service=project directory=/Users/xiaofei.yin fromDirectory INFO 2025-09-27T08:20:10 +127ms service=config path=/Users/xiaofei.yin/.config/opencode/config.json loading INFO 2025-09-27T08:20:10 +1ms service=config path=/Users/xiaofei.yin/.config/opencode/opencode.json loading INFO 2025-09-27T08:20:10 +0ms service=config path=/Users/xiaofei.yin/.config/opencode/opencode.jsonc loading INFO 2025-09-27T08:20:10 +1ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin INFO 2025-09-27T08:20:10 +3ms service=plugin path=opencode-anthropic-auth@0.0.2 loading plugin INFO 2025-09-27T08:20:10 +29ms service=bus type=* subscribing INFO 2025-09-27T08:20:10 +0ms service=bus type=session.updated subscribing INFO 2025-09-27T08:20:10 +0ms service=bus type=message.updated subscribing INFO 2025-09-27T08:20:10 +0ms service=bus type=message.part.updated subscribing INFO 2025-09-27T08:20:10 +0ms service=format init INFO 2025-09-27T08:20:10 +0ms service=bus type=file.edited subscribing INFO 2025-09-27T08:20:10 +1ms service=session id=ses_675bde9a3ffeh8pMDwrhrYA09p version=0.12.1 projectID=26072424ee3750becfd7240c09e7a038ed2f7ff8 directory=/Users/xiaofei.yin title=New session - 2025-09-27T08:20:10.972Z time={"created":1758961210972,"updated":1758961210972} created INFO 2025-09-27T08:20:10 +0ms service=lsp serverIds=typescript, vue, eslint, gopls, ruby-lsp, pyright, elixir-ls, zls, csharp, rust, clangd, svelte, jdtls enabled LSP servers INFO 2025-09-27T08:20:10 +1ms service=bus type=session.updated publishing INFO 2025-09-27T08:20:10 +2ms service=bus type=message.part.updated subscribing INFO 2025-09-27T08:20:10 +0ms service=bus type=session.error subscribing INFO 2025-09-27T08:20:10 +1ms service=session.prompt session=ses_675bde9a3ffeh8pMDwrhrYA09p prompt INFO 2025-09-27T08:20:10 +4ms service=bus type=message.updated publishing INFO 2025-09-27T08:20:10 +0ms service=bus type=message.part.updated publishing INFO 2025-09-27T08:20:10 +1ms service=bus type=session.updated publishing INFO 2025-09-27T08:20:10 +2ms service=models.dev file={} refreshing INFO 2025-09-27T08:20:10 +1ms service=provider init INFO 2025-09-27T08:20:10 +1ms service=provider providerID=openrouter found INFO 2025-09-27T08:20:10 +0ms service=provider providerID=opencode found INFO 2025-09-27T08:20:10 +0ms service=provider providerID=opencode modelID=code-supernova getModel INFO 2025-09-27T08:20:10 +0ms service=provider status=started providerID=opencode getSDK INFO 2025-09-27T08:20:11 +61ms service=provider status=completed duration=61 providerID=opencode getSDK INFO 2025-09-27T08:20:11 +0ms service=provider providerID=opencode modelID=code-supernova found INFO 2025-09-27T08:20:11 +0ms service=session.prompt session=ses_675bde9a3ffeh8pMDwrhrYA09p sessionID=ses_675bde9a3ffeh8pMDwrhrYA09p locking any idea?
Author
Owner

@github-actions[bot] commented on GitHub (Sep 27, 2025):

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

  • #2766: Opencode just hangs - Similar hanging behavior during startup/initialization phase
  • #2512: Opencode stuck in "generating" - TUI becomes unresponsive and gets stuck in generating state
  • #2692: opencode run hangs on WSL - The opencode run command hangs and never completes
  • #2696: Freeze on "generating..." with code-supernova - Freezing on generating state with specific models
  • #2817: Nothing happens - No response after entering prompts, similar to being stuck

The common pattern across these issues is the TUI getting stuck at various stages (initialization, session locking, generating state). Your issue shows it getting stuck at "session locking" which is very similar to the hanging behaviors reported in the above issues.

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

@github-actions[bot] commented on GitHub (Sep 27, 2025): This issue might be a duplicate of existing issues. Please check: - #2766: Opencode just hangs - Similar hanging behavior during startup/initialization phase - #2512: Opencode stuck in "generating" - TUI becomes unresponsive and gets stuck in generating state - #2692: opencode run hangs on WSL - The `opencode run` command hangs and never completes - #2696: Freeze on "generating..." with code-supernova - Freezing on generating state with specific models - #2817: Nothing happens - No response after entering prompts, similar to being stuck The common pattern across these issues is the TUI getting stuck at various stages (initialization, session locking, generating state). Your issue shows it getting stuck at "session locking" which is very similar to the hanging behaviors reported in the above issues. Feel free to ignore if none of these address your specific case.
Author
Owner

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

hmm @eminemead this is interesting... How long will it hang for?

this is pretty weird...

@rekram1-node commented on GitHub (Sep 28, 2025): hmm @eminemead this is interesting... How long will it hang for? this is pretty weird...
Author
Owner

@eminemead commented on GitHub (Sep 29, 2025):

from my observation more than an hour. Usually I'll just kill it by that time. :(

@eminemead commented on GitHub (Sep 29, 2025): from my observation more than an hour. Usually I'll just kill it by that time. :(
Author
Owner

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

yikes that is awful hmm i will have to look into that more for u

@rekram1-node commented on GitHub (Sep 29, 2025): yikes that is awful hmm i will have to look into that more for u
Author
Owner

@lucaspbordignon commented on GitHub (Sep 29, 2025):

Hey @rekram1-node! Just noticed the same happening with me here, after an upgrade from v0.11.2 to v0.13.4 (if it helps)

Noticed I'm also using opencode zen as the provider, but with a different model (GPT5-codex and Grok), wondering if it has anything to do with that

@lucaspbordignon commented on GitHub (Sep 29, 2025): Hey @rekram1-node! Just noticed the same happening with me here, after an upgrade from v0.11.2 to v0.13.4 (if it helps) Noticed I'm also using opencode zen as the provider, but with a different model (GPT5-codex and Grok), wondering if it has anything to do with that
Author
Owner

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

@lucaspbordignon hmm do you see the same logs more or less as OP? if you do:

opencode run hello --print-logs

Also if u don't mind sharing, what countries are yall in? I have seen zen have issues in certain countries due to restrictions

@rekram1-node commented on GitHub (Sep 29, 2025): @lucaspbordignon hmm do you see the same logs more or less as OP? if you do: `opencode run hello --print-logs` Also if u don't mind sharing, what countries are yall in? I have seen zen have issues in certain countries due to restrictions
Author
Owner

@lucaspbordignon commented on GitHub (Sep 29, 2025):

@rekram1-node - Yes, I see basically the same thing (added the full log with MCP startups and so one), it gets stuck after this chunk of logs

I'm currently in Brazil, re country restrictions. Not sure if that is the cause (have been using zen last week with zero issues, just for context)

❯ opencode run hello --print-logs
INFO  2025-09-29T16:24:41 +52ms service=default version=0.13.4 args=["run","hello","--print-logs"] opencode
INFO  2025-09-29T16:24:41 +1ms service=project directory=/Users/lucasbordignon/code fromDirectory
INFO  2025-09-29T16:24:41 +5ms service=config path=/Users/lucasbordignon/.config/opencode/config.json loading
INFO  2025-09-29T16:24:41 +0ms service=config path=/Users/lucasbordignon/.config/opencode/opencode.json loading
INFO  2025-09-29T16:24:41 +4ms service=config path=/Users/lucasbordignon/.config/opencode/opencode.jsonc loading
INFO  2025-09-29T16:24:41 +6ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin
INFO  2025-09-29T16:24:41 +2ms service=plugin path=opencode-anthropic-auth@0.0.2 loading plugin
INFO  2025-09-29T16:24:41 +22ms service=bus type=* subscribing
INFO  2025-09-29T16:24:41 +0ms service=bus type=session.updated subscribing
INFO  2025-09-29T16:24:41 +0ms service=bus type=message.updated subscribing
INFO  2025-09-29T16:24:41 +0ms service=bus type=message.part.updated subscribing
INFO  2025-09-29T16:24:41 +0ms service=format init
INFO  2025-09-29T16:24:41 +0ms service=bus type=file.edited subscribing
INFO  2025-09-29T16:24:41 +1ms service=session id=ses_669b59e4dffejQCpv25pixNIm2 version=0.13.4 projectID=global directory=/Users/lucasbordignon/code title=New session - 2025-09-29T16:24:41.138Z time={"created":1759163081138,"updated":1759163081138} created
INFO  2025-09-29T16:24:41 +0ms service=lsp serverIds=typescript, vue, eslint, gopls, ruby-lsp, pyright, elixir-ls, zls, csharp, rust, clangd, svelte, jdtls enabled LSP servers
INFO  2025-09-29T16:24:41 +0ms service=bus type=session.updated publishing
INFO  2025-09-29T16:24:41 +1ms service=bus type=message.part.updated subscribing
INFO  2025-09-29T16:24:41 +0ms service=bus type=session.error subscribing
INFO  2025-09-29T16:24:41 +0ms service=session.prompt session=ses_669b59e4dffejQCpv25pixNIm2 prompt
INFO  2025-09-29T16:24:41 +2ms service=bus type=message.updated publishing
INFO  2025-09-29T16:24:41 +0ms service=bus type=message.part.updated publishing
INFO  2025-09-29T16:24:41 +1ms service=bus type=session.updated publishing
INFO  2025-09-29T16:24:41 +1ms service=models.dev file={} refreshing
INFO  2025-09-29T16:24:41 +2ms service=provider init
INFO  2025-09-29T16:24:41 +1ms service=provider providerID=google found
INFO  2025-09-29T16:24:41 +0ms service=provider providerID=opencode found
INFO  2025-09-29T16:24:41 +0ms service=provider providerID=anthropic found
INFO  2025-09-29T16:24:41 +0ms service=provider providerID=opencode modelID=grok-code getModel
INFO  2025-09-29T16:24:41 +0ms service=provider status=started providerID=opencode getSDK
INFO  2025-09-29T16:24:41 +48ms service=provider status=completed duration=48 providerID=opencode getSDK
INFO  2025-09-29T16:24:41 +0ms service=provider providerID=opencode modelID=grok-code found
INFO  2025-09-29T16:24:41 +0ms service=session.prompt session=ses_669b59e4dffejQCpv25pixNIm2 sessionID=ses_669b59e4dffejQCpv25pixNIm2 locking
INFO  2025-09-29T16:24:41 +6ms service=mcp key=playwright type=local found
INFO  2025-09-29T16:24:41 +733ms service=mcp key=context7 type=remote found
INFO  2025-09-29T16:24:42 +567ms service=mcp key=figma-dev-mode-mcp-server type=remote found
@lucaspbordignon commented on GitHub (Sep 29, 2025): @rekram1-node - Yes, I see basically the same thing (added the full log with MCP startups and so one), it gets stuck after this chunk of logs I'm currently in Brazil, re country restrictions. Not sure if that is the cause (have been using zen last week with zero issues, just for context) ```shell ❯ opencode run hello --print-logs INFO 2025-09-29T16:24:41 +52ms service=default version=0.13.4 args=["run","hello","--print-logs"] opencode INFO 2025-09-29T16:24:41 +1ms service=project directory=/Users/lucasbordignon/code fromDirectory INFO 2025-09-29T16:24:41 +5ms service=config path=/Users/lucasbordignon/.config/opencode/config.json loading INFO 2025-09-29T16:24:41 +0ms service=config path=/Users/lucasbordignon/.config/opencode/opencode.json loading INFO 2025-09-29T16:24:41 +4ms service=config path=/Users/lucasbordignon/.config/opencode/opencode.jsonc loading INFO 2025-09-29T16:24:41 +6ms service=plugin path=opencode-copilot-auth@0.0.3 loading plugin INFO 2025-09-29T16:24:41 +2ms service=plugin path=opencode-anthropic-auth@0.0.2 loading plugin INFO 2025-09-29T16:24:41 +22ms service=bus type=* subscribing INFO 2025-09-29T16:24:41 +0ms service=bus type=session.updated subscribing INFO 2025-09-29T16:24:41 +0ms service=bus type=message.updated subscribing INFO 2025-09-29T16:24:41 +0ms service=bus type=message.part.updated subscribing INFO 2025-09-29T16:24:41 +0ms service=format init INFO 2025-09-29T16:24:41 +0ms service=bus type=file.edited subscribing INFO 2025-09-29T16:24:41 +1ms service=session id=ses_669b59e4dffejQCpv25pixNIm2 version=0.13.4 projectID=global directory=/Users/lucasbordignon/code title=New session - 2025-09-29T16:24:41.138Z time={"created":1759163081138,"updated":1759163081138} created INFO 2025-09-29T16:24:41 +0ms service=lsp serverIds=typescript, vue, eslint, gopls, ruby-lsp, pyright, elixir-ls, zls, csharp, rust, clangd, svelte, jdtls enabled LSP servers INFO 2025-09-29T16:24:41 +0ms service=bus type=session.updated publishing INFO 2025-09-29T16:24:41 +1ms service=bus type=message.part.updated subscribing INFO 2025-09-29T16:24:41 +0ms service=bus type=session.error subscribing INFO 2025-09-29T16:24:41 +0ms service=session.prompt session=ses_669b59e4dffejQCpv25pixNIm2 prompt INFO 2025-09-29T16:24:41 +2ms service=bus type=message.updated publishing INFO 2025-09-29T16:24:41 +0ms service=bus type=message.part.updated publishing INFO 2025-09-29T16:24:41 +1ms service=bus type=session.updated publishing INFO 2025-09-29T16:24:41 +1ms service=models.dev file={} refreshing INFO 2025-09-29T16:24:41 +2ms service=provider init INFO 2025-09-29T16:24:41 +1ms service=provider providerID=google found INFO 2025-09-29T16:24:41 +0ms service=provider providerID=opencode found INFO 2025-09-29T16:24:41 +0ms service=provider providerID=anthropic found INFO 2025-09-29T16:24:41 +0ms service=provider providerID=opencode modelID=grok-code getModel INFO 2025-09-29T16:24:41 +0ms service=provider status=started providerID=opencode getSDK INFO 2025-09-29T16:24:41 +48ms service=provider status=completed duration=48 providerID=opencode getSDK INFO 2025-09-29T16:24:41 +0ms service=provider providerID=opencode modelID=grok-code found INFO 2025-09-29T16:24:41 +0ms service=session.prompt session=ses_669b59e4dffejQCpv25pixNIm2 sessionID=ses_669b59e4dffejQCpv25pixNIm2 locking INFO 2025-09-29T16:24:41 +6ms service=mcp key=playwright type=local found INFO 2025-09-29T16:24:41 +733ms service=mcp key=context7 type=remote found INFO 2025-09-29T16:24:42 +567ms service=mcp key=figma-dev-mode-mcp-server type=remote found ```
Author
Owner

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

@lucaspbordignon ah in this case the issue is your mcp server, specifically the figma one is causing the hanging

@rekram1-node commented on GitHub (Sep 29, 2025): @lucaspbordignon ah in this case the issue is your mcp server, specifically the figma one is causing the hanging
Author
Owner

@eminemead commented on GitHub (Oct 9, 2025):

@lucaspbordignon hmm do you see the same logs more or less as OP? if you do:

opencode run hello --print-logs

Also if u don't mind sharing, what countries are yall in? I have seen zen have issues in certain countries due to restrictions

I'm in Taiwan/singapore, no restrictions either.

for me, it hangs regardless if I'm using zen or not. meh...

@eminemead commented on GitHub (Oct 9, 2025): > [@lucaspbordignon](https://github.com/lucaspbordignon) hmm do you see the same logs more or less as OP? if you do: > > `opencode run hello --print-logs` > > Also if u don't mind sharing, what countries are yall in? I have seen zen have issues in certain countries due to restrictions I'm in Taiwan/singapore, no restrictions either. for me, it hangs regardless if I'm using zen or not. meh...
Author
Owner

@jayair commented on GitHub (Oct 10, 2025):

@eminemead doesn't matter what model you use? even Claude?

@jayair commented on GitHub (Oct 10, 2025): @eminemead doesn't matter what model you use? even Claude?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#1853