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
backend-sync: sync-local-files returns 500 instead of 207 when Deepgram returns empty transcription #6100
/v1/sync-local-files returns HTTP 500 when Deepgram returns no words for audio segments (silence/noise-only audio). The entire request fails even though the infrastructure is healthy — the audio was simply silent.
Error pattern:
sync_local_files partial failure success=0/N errors=["Deepgram returned no words for segment..."]
Impact
Significant error rate for heavy sync users (paying subscribers using Limitless devices with private_cloud_sync_enabled)
Triggers 5xx alerts unnecessarily — these are not infrastructure failures
Users experience sync failures for recordings that contain silence or low-quality audio segments
Expected Behavior
Empty Deepgram transcription (no words) should be treated as a successful-but-empty segment, not an error
Return 207 Multi-Status with per-segment results:
Segments with transcription → success with content
Segments with no words → success with empty transcript (not an error)
Segments with actual failures (DG timeout, auth error, infra issue) → error
Only return 500 for real infrastructure failures
Current Behavior
Any segment where Deepgram returns no words causes the entire request to fail with 500, even when DG processed the audio successfully — it just had nothing to transcribe.
Location
backend/routers/sync.py — the sync_local_files endpoint
Fix Direction
In the segment processing loop, distinguish between "DG returned successfully but with no words" vs "DG failed"
Treat no-words as a successful empty result, not an exception
Aggregate per-segment results and return 207 when there's a mix of outcomes
Reserve 500 for actual infrastructure errors (timeouts, auth failures, connection errors)
Activity
fix(stt): raise RuntimeError on deepgram_prerecorded retry exhaustion (…
fix(sync): treat empty DG transcription as success, not error (#6100)
test(sync): update tests for empty-words-as-success behavior (#6100)
test(sync): add behavioral tests for DG retry exhaustion and status m…
fix(sync): treat empty DG transcription as success, not error (#6100) (…
fix(stt): raise RuntimeError on deepgram_prerecorded retry exhaustion (…
fix(sync): treat empty DG transcription as success, not error (#6100)
test(sync): update tests for empty-words-as-success behavior (#6100)
test(sync): add behavioral tests for DG retry exhaustion and status m…
fix(stt): raise RuntimeError on deepgram_prerecorded retry exhaustion (…
fix(sync): treat empty DG transcription as success, not error (BasedH…
test(sync): update tests for empty-words-as-success behavior (BasedHa…
test(sync): add behavioral tests for DG retry exhaustion and status m…
fix(sync): treat empty DG transcription as success, not error (BasedH…