Completed
on 7 Jan 2026, 9:33 pm

Output

Fix verified and tested. The reconnect thrashing race condition no longer occurs - status bar stays stable at "Ready" after turn completion.

Quick Actions

Original Request

✅ Bug Fixed: Reconnect Thrashing Race Condition

Root Cause Analysis

When a Claude turn completed:

  1. Stream ended with done === true
  2. checkForNewKontask() called immediately
  3. Kontask not persisted yet → returns false
  4. State machine enters polling state
  5. Heartbeat keeps running, lastEventAt not updated
  6. After 30s, heartbeat dispatches disconnect
  7. State flips between RECONNECTING ↔ DISCONNECTED

Fixes Applied

1. Retry loop5 attempts with exponential backoff (200ms → 1s)
2. Heartbeat fixSkip polling state (has its own timeout)
3. lastEventAtUpdate on EventSource open/events

Files Changed

konui/src/console-streaming.ts | +25 -4
konui/src/console-ui.ts        | +3 -2

Commit

b1c15b5b - Pushed to main

Details

Type General
Status Completed
Scope vibetools
Tags bug-fixconsolestreaming
Created 7 Jan 2026, 6:45 pm

🔗 Git Commit

b1c15b5b
DashboardReportsKontasksFlowsDecisionsSessionsTelemetryLogs + Go