Repository navigation
fix(watch): make Stop visible and release the microphone on cleanup - #23280
Conversation
|
Verdict: the production change here is correct and nicely scoped — no blocking issues; the remaining open items are the ones your own draft checklist already tracks. What I verified on the current head:
Two non-blocking nits: a group's displayed start time uses the earliest currently-known part, so it can shift if an earlier part arrives later (identity stays stable — already covered by your identity test); and "Listening" / "Tap to Record" remain hardcoded English while the new Stop control localizes — pre-existing, worth a follow-up. Blast radius: watchOS recorder + iPhone Home presentation; receipt-owned files, transfers and processing policy are unchanged, and the singleton-group path keeps phone batch recordings pixel-identical. USER IMPACT: Apple Watch shows a clear red Stop button and fully releases the microphone when recording ends; iPhone Home shows one entry per Watch recording session instead of one row per saved minute, with every original part still one tap away. Still want before this leaves draft: the physical paired-device acceptance and the clean full-suite run your checklist already names — nothing else is blocking from my side. by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
|
Verdict: the production change is correct and well scoped - this fixes two real bugs (Stop was invisible behind the Omi logo, and the recorder never released AVAudioSession on any path), and I found no blocking issues. Findings by file:
Security/privacy: materially positive - every stop/cancel/failure path now releases the microphone session instead of retaining it. Blast radius: Watch recorder only; no phone-side, backend, or retention-policy change. USER IMPACT: On Apple Watch, recording now shows a clear red Stop button, and stopping (or a cancelled/failed start) actually releases the microphone instead of keeping it active. Still want before merge - matching your own open checklist items: physical paired-Watch qualification (Stop removes the microphone indicator with the phone both reachable and unreachable, during pending transfers) and the post-main-integration full check rerun. Nothing on the review side blocks this; leaving final merge sign-off to maintainers once the physical paired-device checklist passes. by AI on behalf of David — if you need David’s attention urgently, please @Git-on-my-level and escalate with |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Final merge acceptance — 2026-10-23
Reviewed/tested head
821c326f07846966173b6a66b70c3187094da442. Fresh native suites pass 24 tests / 84 assertions. The production recorder/view/store probe passes 7 lifecycle cases on the 40 mm Watch SE 3 simulator / watchOS 27.0: canceled/late permission, ABA permission, failed activation, Stop, repeated Stop, denial and missing owner. Permission/audio-session I/O is injected;physicalAudio=false. Native screenshots confirm visible Stop and separate Retry with pending transfers, idle Record/Retry, and visible Stop at accessibility3 with a long recovery error. This is not real microphone, radio transfer or paired-Watch evidence.Aryan explicitly accepts simulator-led Omi verification and authorized merging this PR if ready. This final acceptance supersedes the earlier physical-device-only merge gates below; physical Watch connectivity/audio and customer release outcomes remain explicitly unverified follow-up, not claims of recovery. Required current-head CI and an existing approval passed before merge. No deployment or store release is authorized/performed in this task.
Fixeswas changed toRefsso #23275 stays open for release/outcome follow-up rather than closing on code merge alone.The active Watch screen hides Stop behind the Omi logo, and recorder teardown leaves AVAudioSession active. This adds a visible Stop recording button, keeps Retry transfer separate, and shares microphone cleanup across Stop, cancelled permission and failed startup. A delayed permission answer cannot reactivate a cancelled recording.
Refs #23275. Follow-up to #22059.
Current main already addresses minute-by-minute Home backup clutter through #23288: the shared custody ledger owns Watch copies, Offline Sync exposes automatic work, and Home lists explicit user-held recordings. This branch now integrates that pipeline and removes its superseded Home grouping proposal. No additional Dart projection, retention rule, backend, firmware or API change is introduced here. Public store release of #23288 has not been verified.
Verification
Native Watch simulator probe runs the actual production recorder/view/store with synthetic permission and audio-session I/O: 7 lifecycle cases passed, including late/ABA permission, activation failure, Stop, repeated Stop, denial and missing owner. It opens no microphone.
Existing custody, relay and presentation suites: 24 tests, 84 assertions passed after main integration.
Separate Personal Team-signed QA host on physical iPhone 16 Pro / iOS 27.0.1, compiling unchanged production recorder/view/store: the final approximately 70-second capture saved 60.00 + 10.09 seconds of validated, non-zero PCM, stopped, successfully deactivated AVAudioSession with zero errors, and left file sizes unchanged for two seconds. Final result UTC: 2026-10-23T04:22:27Z. A direct-phone spoken test also produced non-zero audio. Aryan manually verified Stop: the timer stopped and orange microphone indicator disappeared. Earlier runs with the Mac device view open contained only zero PCM and are not counted as audible capture evidence; a later start was blocked while the phone was locked. The final run used the unlocked phone directly with the device view closed. Retained parts include earlier QA runs, so totals are attributed by session metadata. The battery adapter is a no-op; this does not exercise physical watchOS, paired delivery or the production Omi app/account.
Native 40 mm Watch simulator renders active Stop + Retry, stopped Record + Retry, and accessibility3/error state. The stopped-state Retry clipping and accessibility title wrapping found during inspection are corrected.
Current-main analyzer ratchet, local preflight (20 selected checks; the history-dependent guard explicitly skips on this shallow clone) and push hooks passed. Full app suite: 7,120 passed, four skipped, plus 138 protected contracts passed. All hermetic mobile journeys passed (23 executions, zero failures/skips). Code Review confirms iOS Compile Check, Dart Analyze & Tests, Hygiene and Desktop Swift Static & Test Contracts passed on
821c326f07846966173b6a66b70c3187094da442, with no failed or running source checks at verification. Scope-skipped lanes are not claimed as executed.Reproduce native checks from the repository root:
The SDK probe needs the CocoaPods Ruby environment (
xcodeproj). Private physical-run build/source hashes and result JSON are retained locally; no microphone audio, device identifier, customer account or signing credential is published.Merge gates and release
Ready for review; do not merge until paired-Watch acceptance passes: press Stop and check microphone indicator with phone reachable/unavailable, pending transfers and screen-off/resume; capture across a minute boundary; restart/retry real WatchConnectivity transfers; verify receipt-owned originals, playback and processing on iPhone; confirm Home has no automatic minute-copy rows and originals remain accessible through Offline Sync. The iPhone-host result does not satisfy these Watch gates. Simulator file delivery is unsupported by Apple's WatchConnectivity documentation. Longer recovery qualification remains tracked in
app/docs/apple-watch-recovery.md.Source checks have passed on the exact pushed head. Complete paired-hardware acceptance and compare against David's concurrent work before readiness; refresh affected checks if changes follow that review. No review of unpublished changes is claimed. After acceptance, this needs merge and a signed iPhone release containing the updated Watch companion. This follow-up adds no backend deployment; #22059's existing processing-backend rollout dependency remains separately tracked. No deployment, app-store release or older-audio recovery is claimed.
Product invariants
INV-CAP-1: preserve original recovery files, session fencing, durable receipts and account ownership; microphone teardown does not change custody.
INV-UI-1 / INV-UI-3: reuse native controls and existing localized Stop labels, preserve explicit controls with pending/error state and large text.
INV-PERF-1: no new per-frame UI work, scan, timer or uploader; main's canonical custody pipeline remains authoritative.
Failure class
Failure-Class: new
Root cause: recorder cleanup stopped the engine without releasing AVAudioSession; permission checking also activated audio before validating the original start generation. Trigger: #23275; these lifecycle defects predate #22059, while that PR introduced the minute-copy clutter now handled by #23288.
Prevention uses a shared
releaseCaptureResourcesprimitive for Stop and failed startup, plus generation validation before session activation. The durable guard isapp/ios/test/watch_recording_controls_probe.rbwithapp/ios/test/fixtures/watch_recording_controls_app.swift, executing the production model with synthetic OS I/O. It is an explicit SDK/simulator lane, not a default hermetic CI or physical Watch qualification.UI evidence
UI-Evidence: .agent-artifacts/ui-evidence/watch-session-controls/evidence.json
Actual native views with synthetic state; no physical microphone or transfer claim.
2026-10-23 maintainer review and merge gates
Reviewed the current production Stop/cleanup/generation changes and reran the native recovery, relay and presentation suites: 24 tests / 84 assertions pass. No new blocking source finding in this bounded review. Existing iPhone-host microphone evidence is not a paired-Watch test. Ready for code review at Aryan's request; merge stays blocked until real Watch Stop/microphone release, minute-boundary capture, reachable/unreachable phone transfer retry, screen-off/resume, retained originals/playback/processing and Home/Offline Sync behavior are verified. No physical device was accessed in this review and no deployment/release was performed.