fix: document non-streaming fallback compatibility with mid-session watchdog (#232)

Confirms usage tracking is correct for non-streaming API responses and
documents the intentional 5-min/2-min timing relationship with CLI v2.1.79.
This commit is contained in:
2026-03-20 10:50:10 -07:00
committed by Naomi Carrigan
parent 1708d307c9
commit 405a8a43fb
+3
View File
@@ -630,6 +630,9 @@ impl WslBridge {
let process_mid_watchdog = self.process.clone();
let pending_since_watchdog = self.pending_since.clone();
let generation_watchdog = self.watchdog_generation.clone();
// 5-minute stuck timeout is intentionally larger than the CLI's 2-minute per-attempt
// non-streaming fallback (added in v2.1.79). A non-streaming response will either
// succeed or fail with a Result message well within this window.
const STUCK_TIMEOUT: Duration = Duration::from_secs(5 * 60);
const POLL_INTERVAL: Duration = Duration::from_secs(30);
thread::spawn(move || {