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
Phone Call: live transcription stuck on "Reconnecting transcription…" for entire call; never shows failure #21278
App 1.0.558 (build 1400), Android, Samsung Galaxy Z Fold7 (SM-F966U)
Omi DevKit 2, firmware 2.0.10
Verified caller ID: US Google Voice number
Steps
Verify a number in Phone Call Settings (succeeds).
Record → Phone Call → dial +1 303 499 7111 (NIST time line, continuous speech).
Call connects; audio both ways is fine.
Expected: transcript segments appear during the call. Actual: status shows "Reconnecting transcription…" for the whole call (reproduced twice, 0:45 and 0:54). No transcript ever appears.
Control test: pendant live transcription on the same account, minutes later, works normally. So credits, auth and /v4/listen are fine in general; the failure is specific to source=phone_call.
Code observations
app/lib/providers/phone_call_provider.dart, _connectTranscriptionSocket(): _wsReconnectAttempts = 0 runs right after the socket is created, before the server accepts it. If the server closes the connection immediately, the counter resets every time, so the backoff stays at 1s and _maxWsReconnectAttempts (10) is never reached. The UI loops on "reconnecting" and never shows "failed". Suggested fix: reset the counter only on the first received message (where _wsAccepted is set).
The onDone handler ignores the socket's closeCode / closeReason, so the server's rejection reason (1008 etc.) is never logged or shown. Please log/surface them; it would identify the root cause.
Related (separate bug)
loadVerifiedNumbers() turns any API failure into an empty list, so Phone Call Settings shows "No Verified Numbers" while POST /v1/phone/numbers/verify returns 409 "Phone number already verified".
phone_setup_number_page.dart expects verificationStatus == 'verified' to redirect, but the backend returns 409 for an already-verified number, so that redirect never runs.
Device diagnostics export available on request / will attach.
Submitted a complete surgical fix and regression test suite in PR #21305.
Summary of Fix:
Reconnect Counter Reset: Moved _wsReconnectAttempts = 0 to trigger only when the transcription connection is acknowledged (_wsAccepted = true on the first message event), removing the premature reset in _connectTranscriptionSocket().
Proper Backoff & Max-Retry Failure: Reconnect attempts now monotonically increment upon consecutive failures, applying true exponential backoff and cleanly transitioning to TranscriptionStatus.failed once _maxWsReconnectAttempts (10) is reached.
Closure Diagnostics: Surfaced closeCode and closeReason logging in the socket's onDone handler.
Regression Tests: Added hermetic unit tests in phone_call_provider_test.dart verifying unaccepted closure backoff, counter reset upon message receipt, and max-retry terminal failure.
Activity
fix(phone-calls): reset transcription reconnect attempts only on acce…
test(phone-calls): add regression tests for transcription reconnect b…
Dragonire9 commentedon Oct 12, 2026
Submitted a complete surgical fix and regression test suite in PR #21305.
Summary of Fix:
_wsReconnectAttempts = 0to trigger only when the transcription connection is acknowledged (_wsAccepted = trueon the first message event), removing the premature reset in_connectTranscriptionSocket().TranscriptionStatus.failedonce_maxWsReconnectAttempts(10) is reached.closeCodeandcloseReasonlogging in the socket'sonDonehandler.phone_call_provider_test.dartverifying unaccepted closure backoff, counter reset upon message receipt, and max-retry terminal failure.fix(phone-calls): prevent infinite reconnect loop and log WebSocket c…