Repository navigation
Conversation
…eturns to full volume
|
I asked Claude to review and got an approval with some comments for you to review. Seems like the interaction with Speak BG may be one thing to consider. Issues
Minor: |
marionbarker
left a comment
There was a problem hiding this comment.
Successful build. Please read the Claude comments as well.
|
I tested the branch for a few days and the two problems that I reported have been resolved. The podcast volume now goes back to where it was between alarm repeats and the Omnipod Dash heartbeat warning no longer shows up. |
|
Thanks Marion. I tested both points on a phone with a podcast playing. The first one is real and worse than a logged error. When an alarm finished while spoken BG was still talking, the session was deactivated under the speech, the speech was cut off mid-sentence, and the synthesizer stayed in speaking state, so every later spoken BG was queued behind it and never heard until the app was restarted. With your isSpeaking check the speech continues to the end, the release happens in didFinish, the podcast comes back and the next spoken BG works. Added in 650194d. On Silent Tune, it turned out not to happen. With Silent Tune holding the session in the background, the alarm never interrupted the podcast, it kept playing through the alarm and afterwards, so there is nothing that needs a resume notice. In the foreground without Silent Tune the alarm does interrupt it, and the podcast resumed on its own right after the release. The Speak BG quick action I'll take in a separate PR. |
…ther audio is ducked and comes back
|
The Speak BG quick action turned out to be small enough to fix here. On a phone it paused a playing podcast, which stayed paused afterwards. It now speaks through the same speech output as spoken BG (b1f5a45), so the podcast is only ducked and keeps playing, both when the app is running and when the quick action launches it. The alarm during spoken BG case still behaves as above with this change. |
…n-release # Conflicts: # LoopFollow/ViewControllers/MainViewController.swift
The alarm releases the audio session with notifyOthersOnDeactivation when it is stopped or snoozed and when its last sound finishes, so audio from other apps that was ducked during the alarm returns to full volume right away, also when the app is kept alive in the background by a Bluetooth heartbeat. With Silent Tune holding the session it stays active and goes back to the mixable category Silent Tune uses. Spoken BG and the Speak BG quick action share one speech output that ducks other audio and uses the same release path, so neither an alarm nor speech deactivates the session while the other is still playing; when an alarm ends during speech, the release happens once the speech finishes.
Related to #782.