Files
kilocode/packages/opencode/src/commit-message
kilo-code-bot[bot]andkiloconnect[bot] c87457ba5a fix(cli,vscode): consume stream explicitly to prevent commit message infinite loading (#7434)
* fix(cli,vscode): prevent infinite loading in commit message generation

Add timeout-based AbortController to both server-side LLM stream (30s)
and client-side HTTP request (35s) so the SCM progress spinner cannot
hang indefinitely. Make the VS Code progress indicator cancellable so
users can abort manually. Also fix outdated test mocks that referenced
the removed getHttpClient API instead of the current SDK getClient.

* fix(cli,vscode): consume stream explicitly to prevent infinite loading

Replace `await stream.text` with `for await (chunk of stream.textStream)`
so that stream-level errors surface immediately instead of leaving the
promise hanging indefinitely. With some providers and Vercel AI SDK
versions, the `.text` promise never resolves when the underlying stream
errors out early, causing the spinner to load forever (fixes #7345).

Add a catch block that distinguishes timeout aborts from other errors
and re-throws with a human-readable message (partially addresses #6568).

In the VS Code extension, log the actual error in the getClient catch
block instead of silently discarding it.

---------

Co-authored-by: kiloconnect[bot] <240665456+kiloconnect[bot]@users.noreply.github.com>
2026-03-24 12:25:17 +01:00
..