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]: dstack attach --logs reports failure after a successful task #4381
If the CLI reports a timeout, check the run again:
dstack run get <run-name> --json
This is timing-dependent. In the observed run, the task performed GPU/environment checks, slept for 30 seconds, and exited successfully.
Actual behaviour
After the logs end, the CLI exits 1 and prints:
Lost run connection. Timed out waiting for run final status. Check `dstack ps` to see if it's done or failed.
The run subsequently reaches done, with job exit code 0. In one observed run, the server took 46.2 seconds after the runner finished to mark the run done. No SSH disconnect was observed while that task was running.
Expected behaviour
The CLI reports the successful result and exits 0. Waiting for the server to finish updating the run should not be reported as a lost connection.
dstack version
Development branch based on master fe6fe22e4, with unchanged shared pipeline and CLI code; runner build 8254.
That scheduling defect was introduced by #3686 in 0.20.14 (opt-in pipelines), enabled by default in 0.20.16 through #3728. This was verified against the preceding code and release tags. The CLI timeout itself is older.
Preserving the timestamp fixes that polling defect, but did not eliminate the CLI timeout in live testing. The remaining finalization delay and the CLI's wait need to be addressed together.
changed the title [-][Bug]: CLI can time out while successful runs are finalizing[/-][+][Bug]: Attached CLI exits 1 after a successful task while the server is still finalizing[/+]on Oct 17, 2026
changed the title [-][Bug]: Attached CLI exits 1 after a successful task while the server is still finalizing[/-][+][Bug]: dstack attach --logs reports failure after a successful task[/+]on Oct 17, 2026
Activity
[-][Bug]: CLI can time out while successful runs are finalizing[/-][+][Bug]: Attached CLI exits 1 after a successful task while the server is still finalizing[/+][-][Bug]: Attached CLI exits 1 after a successful task while the server is still finalizing[/-][+][Bug]: dstack attach --logs reports failure after a successful task[/+]