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
[Bug]: Turn ends as Failed (ENOTFOUND) when the machine goes offline and never resumes when the network returns #39810
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
Start a turn in any thread (seen with Claude) and let the agent work.
While the agent is still running, lose connection (e.g. turn Wi-Fi off).
Keep the machine offline until the provider has used up all its retries (10 in my case).
The turn ends as Failed.
Gain connection back (e.g. turn Wi-Fi back on).
Wait. The thread stays Failed and nothing continues on its own.
Expected behavior
While the device is offline (!net.isOnline()), the thread waits instead of spending retries on a network that is down. When the device is online again, the turn continues without manual action.
Actual behavior
The provider retries 10 times against the dead network, then the turn ends as Failed:
Provider error after 10/10 retries
API Error: Can't reach the API server, check your internet or DNS (ENOTFOUND)
The thread stays Failed. Nothing notices that the network is back, so I type "continue" by hand. This happens whenever I am offline for longer than the retries last, for example when I carry the laptop between places.
I know the ideal setup is a server that runs the agents, with the laptop as an end node like a phone. I don't have that yet, and I think many users run agents directly on a laptop that sleeps or moves, so it would help if the thread recovered by itself.
Notes:
ENOTFOUND alone does not prove an outage (issues below show DNS failures with a working internet) so the class should come from the error code plus the OS online state or a cheap probe (e.g. ping google.com).
Thanks for writing this up. It asks for new behaviour rather than reporting a defect, so it does not belong in the bug tracker and I'm closing it as not planned here. Feature ideas are discussed in Discussions: please post it there.
Activity
juliusmarminge commentedon Nov 20, 2026
Thanks for writing this up. It asks for new behaviour rather than reporting a defect, so it does not belong in the bug tracker and I'm closing it as not planned here. Feature ideas are discussed in Discussions: please post it there.