Process sometimes doesn't close after response is finished #2903

Open
opened 2026-02-16 17:37:44 -05:00 by yindo · 5 comments
Owner

Originally created by @JimmyBenHur on GitHub (Nov 16, 2025).

Originally assigned to: @rekram1-node on GitHub.

Description

I am using a local model with LM Studio, and sometimes (not always) OpenCode waits for further responses, even after it was already finished. You can see this in the interactive as well as the headless mode, where the process also stays open. I then have to abort the operation myself.

To clarify: I do get the actual response, but the process simply doesn't stop after receiving the response.

OpenCode version

1.0.67

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

Windows 11

Terminal

Windows Terminal

Originally created by @JimmyBenHur on GitHub (Nov 16, 2025). Originally assigned to: @rekram1-node on GitHub. ### Description I am using a local model with LM Studio, and sometimes (not always) OpenCode waits for further responses, even after it was already finished. You can see this in the interactive as well as the headless mode, where the process also stays open. I then have to abort the operation myself. To clarify: I do get the actual response, but the process simply doesn't stop after receiving the response. ### OpenCode version 1.0.67 ### Steps to reproduce _No response_ ### Screenshot and/or share link _No response_ ### Operating System Windows 11 ### Terminal Windows Terminal
yindo added the bug label 2026-02-16 17:37:44 -05:00
Author
Owner

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

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

  • #3213: Bug: opencode run and TUI exits hang on v0.15+ - describes exact same symptoms where processes don't close after completion in both interactive and headless modes
  • #4255: OpenCode v1.0.25 Hangs Indefinitely with LM Studio + Qwen Models Due to Empty tool_calls Array - comprehensive analysis of hanging issues with LM Studio models, specifically mentions Windows 11 environment
  • #4319: Strangely enough, it always gets stuck or encounters an exception during task execution - reports similar hanging/stuck behavior during execution
  • #3846: No response to user input - reports UI becoming unresponsive and requiring process termination

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

@github-actions[bot] commented on GitHub (Nov 16, 2025): This issue might be a duplicate of existing issues. Please check: - #3213: Bug: `opencode run` and TUI exits hang on v0.15+ - describes exact same symptoms where processes don't close after completion in both interactive and headless modes - #4255: OpenCode v1.0.25 Hangs Indefinitely with LM Studio + Qwen Models Due to Empty tool_calls Array - comprehensive analysis of hanging issues with LM Studio models, specifically mentions Windows 11 environment - #4319: Strangely enough, it always gets stuck or encounters an exception during task execution - reports similar hanging/stuck behavior during execution - #3846: No response to user input - reports UI becoming unresponsive and requiring process termination Feel free to ignore if none of these address your specific case.
Author
Owner

@rekram1-node commented on GitHub (Nov 16, 2025):

@JimmyBenHur I think this is a preceived hang just because it is waiting for the step-stop, if it is a local llm these things take longer so even though it looks "done" the code is still pending until the llm says it is done

With faster models or providers this shouldn't be an issue

@rekram1-node commented on GitHub (Nov 16, 2025): @JimmyBenHur I think this is a preceived hang just because it is waiting for the step-stop, if it is a local llm these things take longer so even though it looks "done" the code is still pending until the llm says it is done With faster models or providers this shouldn't be an issue
Author
Owner

@rekram1-node commented on GitHub (Nov 16, 2025):

can u replicate it consistently? Maybe show opencode run hello --print-logs

@rekram1-node commented on GitHub (Nov 16, 2025): can u replicate it consistently? Maybe show `opencode run hello --print-logs`
Author
Owner

@JimmyBenHur commented on GitHub (Nov 16, 2025):

Might be a hang, but I already waited a few minutes and the process wouldn't close.
I'm trying to reproduce it with logs, but right now it's working. Will send them as soon as I can reproduce it.
I had the issue with Qwen3 Coder, that's already a pretty fast model I think.

@JimmyBenHur commented on GitHub (Nov 16, 2025): Might be a hang, but I already waited a few minutes and the process wouldn't close. I'm trying to reproduce it with logs, but right now it's working. Will send them as soon as I can reproduce it. I had the issue with Qwen3 Coder, that's already a pretty fast model I think.
Author
Owner

@rekram1-node commented on GitHub (Nov 16, 2025):

Yeah lmk if u get it again

@rekram1-node commented on GitHub (Nov 16, 2025): Yeah lmk if u get it again
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#2903