Repository navigation
Custom commands fail when (even unused) provider is in config file #2205
Copy link
Copy link
Closed
Description
Excerpt from end of dev.log:
INFO 2025-08-23T14:39:05 +31308ms service=server method=POST path=/session/ses_728a212f9ffed4Oi2zPmI2f0CK/command request
INFO 2025-08-23T14:39:05 +0ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK chatting
INFO 2025-08-23T14:39:05 +10ms service=bus type=storage.write publishing
INFO 2025-08-23T14:39:05 +0ms service=bus type=message.updated publishing
INFO 2025-08-23T14:39:05 +1ms service=bus type=storage.write publishing
INFO 2025-08-23T14:39:05 +0ms service=bus type=message.part.updated publishing
INFO 2025-08-23T14:39:05 +1ms service=bus type=storage.write publishing
INFO 2025-08-23T14:39:05 +0ms service=bus type=session.updated publishing
DEBUG 2025-08-23T14:39:05 +1ms service=tui timeTakenMs=0 messages.renderView
INFO 2025-08-23T14:39:05 +1ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK sessionID=ses_728a212f9ffed4Oi2zPmI2f0CK locking
DEBUG 2025-08-23T14:39:05 +0ms service=tui message=msg_8d75e67c3001OuIHYIW5FjvjOA part=prt_8d75e67c3002xIcnrPHylJfLoV message part updated
DEBUG 2025-08-23T14:39:05 +1ms service=tui pending render, skipping
DEBUG 2025-08-23T14:39:05 +0ms service=tui pending render, skipping
DEBUG 2025-08-23T14:39:05 +1ms service=tui timeTakenMs=1 messages.renderView
DEBUG 2025-08-23T14:39:05 +2ms service=tui timeTakenMs=0 messages.renderView
INFO 2025-08-23T14:39:05 +6ms service=bus type=storage.write publishing
INFO 2025-08-23T14:39:05 +1ms service=bus type=message.updated publishing
INFO 2025-08-23T14:39:05 +2ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK type=start part
ERROR 2025-08-23T14:39:05 +4ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK error={"error":{"code":"ConnectionRefused","path":"http://127.0.0.1:1234/v1/chat/completions","errno":0}} streamText error
INFO 2025-08-23T14:39:05 +0ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK type=error part
ERROR 2025-08-23T14:39:05 +0ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK error=Unable to connect. Is the computer able to access the url?
INFO 2025-08-23T14:39:05 +0ms service=bus type=session.error publishing
DEBUG 2025-08-23T14:39:05 +1ms service=tui timeTakenMs=3 messages.renderView
INFO 2025-08-23T14:39:05 +0ms service=bus type=storage.write publishing
INFO 2025-08-23T14:39:05 +0ms service=bus type=message.updated publishing
INFO 2025-08-23T14:39:05 +0ms service=session session=ses_728a212f9ffed4Oi2zPmI2f0CK sessionID=ses_728a212f9ffed4Oi2zPmI2f0CK unlocking
INFO 2025-08-23T14:39:05 +0ms service=bus type=session.idle publishing
INFO 2025-08-23T14:39:05 +1ms service=server duration=33 response
ERROR 2025-08-23T14:39:05 +4ms service=tui message=Error: Unable to connect. Is the computer able to access the url? name=UnknownError Server error
DEBUG 2025-08-23T14:39:05 +4ms service=tui timeTakenMs=0 messages.renderView
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Activity
github-actions commentedon Aug 23, 2025
This issue might be a duplicate of existing issues. Please check:
Your specific error shows a ConnectionRefused to localhost:1234, which suggests you may be trying to connect to a local LLM server (like LM Studio, Ollama, etc.) that isn't running or accessible. Please check if your local server is running on that port.
Feel free to ignore if none of these address your specific case.
aspiers commentedon Aug 23, 2025
I do have LMStudio configured in my
providerssection, but this problem manifests even when I'm using Anthropic /sonic/ GPT-5, so I don't think the localhost:1234 error is relevant.aspiers commentedon Aug 23, 2025
Ah! Sorry, looks like it's relevant after all. If I remove the
providerssection then custom commands start working again. But everything else was working even with the reference to a non-running LMStudio on port 1234, so this is a bug. It should not be necessary to add an LMStudio entry toprovidersevery time you want to use it and remove it every time you shut LMStudio down.[-]Running custom command causes "Error: Unable to connect. Is the computer able to access the url?"[/-][+]Custom commands fail when (even unused) provider is in config file[/+]aspiers commentedon Aug 23, 2025
Issue title updated. Just to clarify, I had this fragment in
opencode.jsonwhich comes directly from the docs:If I start up LM Studio and load the
liquid/lfm2-1.2bmodel, even with opencode configured to usesonic, shockingly it attempts to use that local model (and not even Gemma which is the one in the config file!). So it looks like there is something really weird with how custom commands invoke LLM providers.opencode: work around anomalyco/opencode#2205
rekram1-node commentedon Dec 28, 2025
[automated] Closing due to 90+ days of inactivity. Feel free to reopen if you still need this!