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
I am running ollama on my local network on a dedicaled m4 24gig with Qwen3:14b Quant with 65k context window.
I had it create a slightly more than basic react app and it created things, wrote some of the thngs in the dialog and wrote 50% of the things to disk, the other 50 it didn't I gave it a command to write the rest of the items...and then it did some, but not all of it, i did another command to finish...and now it just timesout.
I am reading the ollama serve logs and noticed that open code is sending a timeout singnal around 4 min ond each time.
So...the issue is opencode.
I didn't set a timeout in the config. Then i tried setting a timeout in the opencode config to 600 seconds, same results.
Is this the right way to do it? Or is this something that can't be changed. Thanks! OpenCode.ai special sauce is going to be for those homebuilds which are going to have less resources and as a result opencode needs to be able to wait longer. Love the community thoughts or is this coming soon. I think there was 3 releases yesterday so i know things are happening rapidly.
Is there a way to set this project to wait a certain time length max or indefinitely? Or does this have a default waiting period occuring at some stage of the project? Maybe some &http.Client method has a default timeout? I'm in a dr office waiting with my eyes dialated so can't really see anymore.. but maybe these notes help
Maybe same as #655, opencode does not complete a download service but ends abruptly. My scenario is upgrading software packages in the Gentoo overlay. The download stops halfway, causing the Manifest that records the package to write an incorrect checksum.
i see timeouts here, i have no idea how this might be effecting http.client requests to an llm or requests for other things, but i think there is a possible issue somehere.
@thdxr i think the real pillar of strength that claude and google can't take from this project will be the ability to use local models which are obvious always going to run slower. I do think testing on a slow response scenario where from a separate machine running ollama might not response for 7 min while it thinks is a worthy test case to backtrack and find where open code might be closing the connection pre-maturely.
Reacted by Rick Stoner, Alistair Stewart, k4ss4n, cyjin.yl, askoan and MichalNawrocik
Reacted by Gabriel Garrett, Rick Stoner, Julio Daniel Reyes, k4ss4n, Laelia-Succubus, Robert Baskette, Akira Makino, Roberto Canha, agentic-ai-forge and sleebu
Same here, getting constant timeouts with ollama. When this happens, the request is not aborted so the model keeps churning and subsequent requests are more likely to fail as the model is busy.
I've been looking into this the last few days. By default a lot of network requests time out after 5 minutes. I'm submitting a PR to mlx-lm to send back SSE comments which notify that the prompt is currently processing and keep the connection alive. If necessary we could make similar keepalive tweaks to ollama and llama.cpp etc to allow time for local models to process very large contexts without all the clients disconnecting
For those that are blocked by the fix being merged, I've found that https://github.com/charmbracelet/crush works as well as opencode and doesn't suffer from the timeout issue.
support will be added in next release thx for your patience
Reacted by Beshoy Girgis, Andrew Black, Seth Jones, Joshua Kuestersteffen, Stephen M. Clark, Danny França, Henrik Mohr, Artem R, eduardogarre and Chaos
Thanks for timeout provider option, it works great.
I need an increased timeout with my computer without GPU
@Cyrille37 I'm look for a solution to this issue. Based on your comment it seems you managed to do this, may I ask how did you do it to enable longer timeouts? Thank you!
Activity
thdxr commentedon Jul 16, 2025
hmm im not sure where this timeout is being set - i don't think that
timeoutoption existsmrbm commentedon Jul 16, 2025
I am not attempted to be super familiar with the code base, but just a quick search brings me to this:
https://github.com/sst/opencode/blob/dev/packages/opencode/src/util/timeout.ts
Is there a way to set this project to wait a certain time length max or indefinitely? Or does this have a default waiting period occuring at some stage of the project? Maybe some &http.Client method has a default timeout? I'm in a dr office waiting with my eyes dialated so can't really see anymore.. but maybe these notes help
douglarek commentedon Jul 17, 2025
Maybe same as #655, opencode does not complete a download service but ends abruptly. My scenario is upgrading software packages in the Gentoo overlay. The download stops halfway, causing the Manifest that records the package to write an incorrect checksum.
mrbm commentedon Jul 17, 2025
https://github.com/sst/opencode/blob/60b55f9d921805a4a9d38c9eed05a060df08df82/packages/opencode/src/tool/bash.ts
i see timeouts here, i have no idea how this might be effecting http.client requests to an llm or requests for other things, but i think there is a possible issue somehere.
mrbm commentedon Jul 17, 2025
@thdxr i think the real pillar of strength that claude and google can't take from this project will be the ability to use local models which are obvious always going to run slower. I do think testing on a slow response scenario where from a separate machine running ollama might not response for 7 min while it thinks is a worthy test case to backtrack and find where open code might be closing the connection pre-maturely.
thdxr commentedon Jul 24, 2025
yep will look into this
noahfraiture commentedon Jul 28, 2025
I agree that timeout would be very convenient, but also for other capabilities like bash execution
ggaabe commentedon Jul 31, 2025
running into timeouts from slow local model responses as well. would be great to control.
dc-tec commentedon Aug 1, 2025
Same here when running a larger local model, would be nice if we could configure the timeout.
dysangel commentedon Aug 3, 2025
same. My model was trying to do multiple tool calls and eventually timing out. I'd be happy to just be able to disable the timeout for local use
egyptianbman commentedon Aug 9, 2025
Same here, getting constant timeouts with ollama. When this happens, the request is not aborted so the model keeps churning and subsequent requests are more likely to fail as the model is busy.
dysangel commentedon Aug 9, 2025
I've been looking into this the last few days. By default a lot of network requests time out after 5 minutes. I'm submitting a PR to mlx-lm to send back SSE comments which notify that the prompt is currently processing and keep the connection alive. If necessary we could make similar keepalive tweaks to ollama and llama.cpp etc to allow time for local models to process very large contexts without all the clients disconnecting
jamviking commentedon Aug 9, 2025
As I am experiencing the same timeout issue when running OpenCode against a local LMStudio installation, us local users need a way to override the default NodeJS timeout as documented here: https://blog.appsignal.com/2023/11/08/how-to-use-timeouts-in-nodejs.html
Hope this helps as I need it...
dysangel commentedon Aug 9, 2025
@jamviking if you're using an MLX model, then yes that issue is still present
8 remaining items
egyptianbman commentedon Aug 18, 2025
For those that are blocked by the fix being merged, I've found that https://github.com/charmbracelet/crush works as well as opencode and doesn't suffer from the timeout issue.
dysangel commentedon Aug 18, 2025
my fix for mlx-lm was merged into main, so if you set up an MLX server now, you should have no timeout issues
eduardogarre commentedon Aug 24, 2025
Also affected by this issue
mrbm commentedon Aug 24, 2025
Hey @thdxr just making sure you saw this and the solution somebody provided.
adamwlarson commentedon Aug 26, 2025
also impacted by this
dannyfranca commentedon Aug 30, 2025
1+, Using GPT-5 with Opencode and high reasoning is not practical at all.
rekram1-node commentedon Aug 31, 2025
support will be added in next release thx for your patience
Cyrille37 commentedon Nov 5, 2025
Thanks for
timeoutprovider option, it works great.I need an increased timeout with my computer without GPU
wangsen992 commentedon Dec 16, 2025
@Cyrille37 I'm look for a solution to this issue. Based on your comment it seems you managed to do this, may I ask how did you do it to enable longer timeouts? Thank you!
rekram1-node commentedon Dec 16, 2025
@wangsen992 what version are u on, what timeouts are u seeing?
Cyrille37 commentedon Dec 17, 2025
@wangsen992 Added
timeoutin provider's options config. Have a look at #3708 for an example.Cyrille37 commentedon Dec 17, 2025
Also, this option is not in documentation, only found in config schema.
dysangel commentedon Dec 17, 2025
@Cyrille37 thanks! I'll have to try open again sometime
chore(deps-dev): bump c8 from 10.1.3 to 11.0.0 (anomalyco#1065)