Skip to content

feat(app): truthful transcription-outage status and pending-transcription counts while recordings drain - #18838

Merged
Git-on-my-level merged 3 commits into
mainfrom
feat/transcription-unavailable-ux
Sep 25, 2026
Merged

Git-on-my-level merged 3 commits into
mainfrom
feat/transcription-unavailable-ux

Conversation

@Git-on-my-level

@Git-on-my-level Git-on-my-level commented Sep 25, 2026 •

Copy link
Copy Markdown
Member

Summary

When the server terminally fails live transcription (stt_failed), the app kept showing a bare "Transcription unavailable" label and then said nothing about the recordings piling up afterwards. Audio keeps flowing into the WAL the whole time, so the capture surfaces should say that, and the recovery drain should be visible as a count.

Changes

  • Outage copy (capturing page + in-progress card). captureStateLabel resolves the transcriptionUnavailable state to the full sentence — "Transcriptions are unavailable, recording continues on device and will process later" — with a compact variant ("Transcription unavailable · saving on device") used by the conversations list's in-progress card, where the full sentence cannot fit. The shared state header wraps the sentence (smaller, up to three lines) instead of ellipsizing away the "recording continues" half. Settings and the phone-call page keep the bare "Transcription unavailable" key (different flows).
  • Backlog draining visibility. The live-capture WAL indicator adds a "Transcriptions pending X/Y" count line once the session has a queue (2+ recordings), fed by LocalWalSyncImpl.getSessionWals (same window/storage scope as getSessionUnsyncedWals, minus the status filter) surfaced through CaptureProvider.sessionTranscriptionBacklogCounts. The conversations list gets a compact "Transcriptions pending N" banner while phone-local recordings wait to upload (SyncProvider.pendingLocalTranscriptionWals: miss + uploaded-but-processing WALs on disk; device-side SD/flash files are a different drain); tapping opens the sync surface that drains them.
  • Polish. The capturing page's empty state no longer promises "Listening… a transcript will appear here" during a terminal outage; it resolves to the same shared outage sentence (after out-of-credits, before offline), so one moment keeps one name.

Line-Count-Exception: app/lib/services/capture/capture_controller.dart | 3124 -> 3137 | one 13-line read-only getter (sessionTranscriptionBacklogCounts) feeding the live-capture backlog chip; no behavior moved or split

Testing

  • app/test/unit/capture_state_labels_test.dart — full/compact outage labels; compact leaves other states untouched.
  • app/test/widgets/conversation_detail_ux_test.dart — the outage sentence wraps in the shared state header on a phone-sized surface.
  • app/test/widgets/transcription_paused_warning_test.dart — the in-progress card shows the compact variant until the backend is ready again.
  • app/test/unit/session_wal_sync_test.dart, app/test/unit/capture_backlog_counts_test.dart — getSessionWals scope and the pending/total counts getter.
  • app/test/widgets/capturing_wal_backlog_test.dart — the chip renders "Transcriptions pending 3/9" while draining and stays hidden for a single queued recording.
  • app/test/widgets/pending_transcriptions_banner_test.dart — banner count, scope (disk only, uploaded counts as pending) and self-hiding.
  • app/test/widgets/capturing_empty_state_test.dart — the stale Listening placeholder is gone during a terminal outage and intact on a healthy session.
  • app/test/spine/c3_conversation_test.dart (existing) — keeps guarding the conversations page embedded without a SyncProvider; the banner resolves it optionally (_maybeProvider idiom) and the visual-audit inert stubs implement the new getter.
  • Full suite: bash test.sh (hermetic unit/widget/spine) and OMI_PR_BODY_FILE=PR_BODY.md make preflight (22 checks) both pass.

Review in cubic

… fails

The live-capture surfaces named a server-side STT failure 'Transcription
unavailable' and stopped there, leaving the reader to guess whether the
wearable/recording was still working. Audio keeps flowing into the WAL
regardless, so the status should say so.

captureStateLabel now resolves the transcription-unavailable state to the
full sentence ('Transcriptions are unavailable, recording continues on
device and will process later') with a compact variant
('Transcription unavailable - saving on device') for space-constrained
surfaces: the conversations list's in-progress card passes compact: true,
while the capturing page keeps the full sentence. The shared state header
wraps the sentence (smaller, up to three lines) instead of ellipsizing
away the 'recording continues' half. Settings and the phone-call page
keep the bare 'Transcription unavailable' key - different flows.
…drains

After a transcription outage recovers, recorded audio uploads recording
by recording, but neither the capturing page nor the conversations list
said how much was left - just a duration that slowly shrank.

The live-capture WAL indicator now adds a 'Transcriptions pending X/Y'
count line once the session has a queue (two or more recordings), fed by
LocalWalSyncImpl.getSessionWals - the same window and storage scope as
getSessionUnsyncedWals, minus the status filter - surfaced through
CaptureProvider.sessionTranscriptionBacklogCounts. The conversations
list also gets a compact 'Transcriptions pending N' banner while
phone-local recordings wait to upload (SyncProvider.pendingLocalTranscriptionWals:
miss and uploaded-but-processing WALs on disk, not device-side files);
tapping it opens the sync surface that drains them. The banner resolves
SyncProvider optionally (the _maybeProvider idiom) so hermetic fixtures
embedding the conversations page without one keep building, and the
visual-audit inert stub implements the new getter.
With no transcript segments yet, the capturing page's empty state kept
promising 'Listening... a transcript will appear here' even after the
server said live transcription cannot run - waiting copy next to a state
that can never resolve. The empty state now resolves the terminal-failure
branch (after out-of-credits, before offline) to the same shared outage
sentence the app bar names, so one moment still has one name. Adds the
mobile changelog fragment for the PR.
@Git-on-my-level
Git-on-my-level merged commit d3d945c into main Sep 25, 2026
45 checks passed
@Git-on-my-level
Git-on-my-level deleted the feat/transcription-unavailable-ux branch September 25, 2026 04:26
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.

1 participant