[Bug] Background play audio drops a few seconds after minimizing the app
Checklist
- [x] I make sure that the issue is NOT a duplicate of pinned issues
- [x] I make sure I am using the LATEST version - check here
- [x] I understand that issues with limited impact, such as those occurring on specific devices or under specific network conditions, will not be fixed
- [ ] I have attached the error report in the issue
Describe the bug
Audio drops out a few seconds after selecting "play in background", then minimizing the app or locking the phone.
Version
5.2.0
Frequency
Often (80-90% of the time)
Device
Pixel 9, Android 17
Steps to reproduce the bug
- Long press a video > "Start playing in the background"
- Minimize the app or lock the phone
- Audio drops (but the media keeps playing) until the app is brought to foreground again
Additional context
I have "allow background usage" enabled in app permissions. One workaround is to start playing the video first (not in background) then switch to "play in background". After that, the audio will keep working even when the app loses focus. This might be a regression in 5.2.0, since this only started happening after updating.
It's can also related to System Update (since Android 17 stable is released last month) Can you downgrade to 5.1.1 and check if the issue persists? You can first backup your data.
It's working fine after downgrading to 5.1.1
is there any error report?
Not that I can see - there was no error notification.
I did not do further testing (yet), but noticed this:
- Start playing a video
- Minimize the app or lock the phone
- Audio drops after a few seconds
However, after trying the suggested workaround (start playing the video first (not in background) then switch to "play in background"), it seemed to work again for this specific video, even after force stopping the app and clearing cache.
Starting another video and locking ths screen lead to the audio stopping after a few seconds.
I did not do further testing (yet), but noticed this:
1. Start playing a video 2. Minimize the app or lock the phone 3. Audio drops after a few secondsHowever, after trying the suggested workaround (start playing the video first (not in background) then switch to "play in background"), it seemed to work again for this specific video, even after force stopping the app and clearing cache.
Starting another video and locking ths screen lead to the audio stopping after a few seconds.
Hello are u using SABR by any chance ?
@Priveetee "Force SABR" is disabled, is that what you mean?
On android 17 btw, since that was mentioned before.
https://developer.android.com/about/versions/17/changes/bg-audio
Relevant?
https://developer.android.com/about/versions/17/changes/bg-audio
Relevant?
Thx u, yes it can be :)
For what it's worth I am now experiencing this on 5.2.1-beta2 (force SABR enabled)
Likely Android 17 issue since @Couchy and @dvg48 are all using android 17
Likely Android 17 issue since @Couchy and @dvg48 are all using android 17
Seems like it, but I tried this adb command given on the page I linked, and it didn't help.
adb shell cmd audio set-enable-hardening disable
I think it's a regression (bug) in Android 17 release since I can't reproduce it on an Android 17 (beta) simulator
even with adb shell cmd audio set-enable-hardening throw
Ah, the command they listed is wrong. The actual command is "set-hardening" (no enable). If I do this, the problem goes away, so this is in fact the issue.
adb shell cmd audio set-hardening disable
I set it to "throw" and saw this error when the audio cuts out:
2026-06-30 22:14:55.975 18374 24073 InfinityLoop1309.NewPipeEnhanced E MediaCodecAudioRenderer : Audio sink error androidx.media3.exoplayer.audio.AudioSink$WriteException: AudioTrack write failed: -4 at androidx.media3.exoplayer.audio.DefaultAudioSink.drainOutputBuffer(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:219) at androidx.media3.exoplayer.audio.DefaultAudioSink.processBuffers(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:1) at androidx.media3.exoplayer.audio.DefaultAudioSink.handleBuffer(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:429) at androidx.media3.exoplayer.audio.MediaCodecAudioRenderer.processOutputBuffer(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:46) at androidx.media3.exoplayer.mediacodec.MediaCodecRenderer.drainOutputBuffer(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:281) at androidx.media3.exoplayer.mediacodec.MediaCodecRenderer.render(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:84) at androidx.media3.exoplayer.ExoPlayerImplInternal.doSomeWork(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:133) at androidx.media3.exoplayer.ExoPlayerImplInternal.handleMessage(r8-map-id-8bc81477e132b1fa6e332502f5ec7c31732304b8f4f8e724c0c3cc42eda8da5f:386) at android.os.Handler.dispatchMessageImpl(Handler.java:138) at android.os.Handler.dispatchMessage(Handler.java:125) at android.os.Looper.loopOnce(Looper.java:296) at android.os.Looper.loop(Looper.java:397) at android.os.HandlerThread.run(HandlerThread.java:139)
log_2026_06_30_22_17_50.log
test this: https://send.vis.ee/download/a7a66f5264a61910/#d_sxjrBMBnQDR-kXf6YX8w
test this: https://send.vis.ee/download/a7a66f5264a61910/#d_sxjrBMBnQDR-kXf6YX8w
This didn't fix it.
@Couchy do you have log?