Handset Snips Music at the Ankles

A few days ago my Pixel 4a phone, running Android 13, started exhibiting a problem where I can play music in VLC, pause it with my Bluetooth headset, wait a few minutes, and when I unpause with the same headset, I get no response. Crickets. No music plays.

So I wake up the screen, see that the Android Media Control in the windowshade is active and showing my session with VLC, and manually press the Play button. Nothing. The icon changes from the Play icon to Pause, as if it was actually playing. Progress bar doesn’t move. No music.

So I flip back through my Activities to find VLC, press the Play button there, and the music plays. Likewise, I could wake up the Assistant and tell it to ask VLC to play a song, which it cheerfully commands and VLC cheerfully plays.

“What the ever-living hell is going on?” I ask myself. I had no idea, so I started debugging by bouncing Bluetooth, unpairing and pairing the headset, rebooting the phone, uninstalling any new apps since last week, clearing the cached VLC data and rescanning my media, going into the Media Session settings, even going down to the system media services and clearing cache. No improvement. Scanned for and applied a monthly Android security and bugfix patch. Still, no luck. I grabbed at every low-hanging fruit I could find.

I just get so aggravated when something so basic is broken, and so many things under the hood in Android are too much of a black box for me to understand what’s not working. Especially aggravating because I f’n work with Android on the daily as part of my engineering job.

But something about the failure signature reminded me of a previous issue that I had with Plex Media Player, where playback would just cease after a few minutes of playing in the background. Oh, is the power management policy for backgrounded apps suddenly too aggressive? Did Android push a policy change that I triggered after running my battery low recently?

I looked at the battery usage policy for VLC; sure enough, it was set to “Optimized”.

Battery usage policy for VLC, when Optimized, will kill an idle session. Set to Unrestricted.

One would think that sending a Bluetooth or Media Session command to resume playback would send an intent to VLC to wake it back up, prompting the kernel to unfreeze the app, but you’d be wrong. Something changed recently, and I don’t know what.

The workaround is to change the battery policy from Optimized to Unrestricted. Now VLC never freezes when paused. I should test this with other media apps.

It could very well be something VLC did to break compliance with Android 13’s constantly changing APIs, to where it’s not correctly begging Android for the right behavior, and as a result Android plays the snippy bitch and cuts VLC off at the ankles. Dumb VLC. Stupid Android. God dammit.

At least I have a workaround and my music controls back.

Stupid, stupid fucking Android.

Published by Shawn

He's just this guy, you know?

One reply on “Handset Snips Music at the Ankles”

Comments are closed.