Skip to content

chore: CLI live-reconnect workstream completion (fix in kilocode#12393)#4629

Merged
iscekic merged 7 commits into
mainfrom
fix/cli-live-reconnect
Jul 21, 2026
Merged

chore: CLI live-reconnect workstream completion (fix in kilocode#12393)#4629
iscekic merged 7 commits into
mainfrom
fix/cli-live-reconnect

Conversation

@iscekic

@iscekic iscekic commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Workstream completion vehicle — CLI live-reconnect

This is the cloud-repo completion tracker for the CLI live-reconnect fix. The defect and its fix are entirely in the Kilo CLI connection layer, so this PR carries no cloud code changes.

Summary of the delivered fix (see kilocode#12393 for the code)

A remote CLI session could silently lose its session-ingest connection and never reconnect until the CLI was restarted, leaving the mobile app showing a live CLI session as frozen/read-only. Root causes were all in the CLI client: unbounded token acquisition, an unbounded CONNECTING attempt, and a wedged heartbeat gather that permanently stopped heartbeats across reconnects. The fix bounds token acquisition, adds a single fenced retry owner with a connection-attempt deadline, bounds the heartbeat gather with a degraded last-known-good fallback, and fences attach announcements on fresh-gather session-id containment.

Verification (performed against this worktree's local stack)

  • Deterministic unit coverage: 16 acceptance tests fail on the unmodified baseline and pass on the fix; remote-ws.test.ts 39 pass, attached-state.test.ts green, typecheck clean.
  • On-device E2E: healthy session renders live with a working composer; after a connection drop the CLI auto-reconnects (same process, no restart) and the session returns live on mobile.

Cross-link: Kilo-Org/kilocode#12393.

@kilo-code-bot

kilo-code-bot Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Executive Summary

This PR is a workstream-completion tracker whose net diff against current main is empty (the referenced .kilo docs changes already merged via #4619), and the actual fix lives in Kilo-Org/kilocode#12393, so there is no cloud-repo code to review.

Files Reviewed (0 files)
  • No files differ between this branch and main; nothing to review.

Reviewed by claude-sonnet-5 · Input: 22 · Output: 4.2K · Cached: 492.4K

Review guidance: REVIEW.md from base branch main

@iscekic
iscekic merged commit 68b209f into main Jul 21, 2026
38 checks passed
@iscekic
iscekic deleted the fix/cli-live-reconnect branch July 21, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants