Endless getTranscodeDecision calls when transcodeParams changes (~4/s, even while paused)

App version

Production

Issue description

I use Lyrion with the SlimPing plugin and I saw a similar behavior in Symfonium 15.1.0 (Android) like in this thread: Same transcoded track re-requested multiple times per session (~1.9x overfetching), higher mobile data than bitrate cap implies - #26 by Tolriq

Here is more info. Claude helped me with analyzing all the logs:

In my case, getTranscodeDecision runs in a loop for the upcoming tracks in the queue: 3–6 times per second, even while paused, for hours. That’s about 25–35 MB per hour on mobile data. SlimPing returns a different transcodeParams on every call, because the expiry has sub-second precision and the JSON key order is random. Each new token changes the prepared URL, so Symfonium prepares the track again:

MediaPrepareManager: Preparing … [sq_tr_3601249]
→ POST getTranscodeDecision?mediaId=sq_tr_3601249
← 200 transcodeParams=eyJpZCI6…
MediaPrepareManager: Prepared from provider … getTranscodeStream…&transcodeParams=eyJpZCI6…
MusicPlayer: updateNextMedia: 2455ad65-…
ExoPlayer: timeline … reason=PLAYLIST_CHANGED
MediaPrepareManager: Preparing … [sq_tr_3601249]
→ POST getTranscodeDecision?mediaId=sq_tr_3601249
← 200 transcodeParams=eyJiciI6… (new token)
… every ~230 ms, 413 calls in 2.5 min, 412 distinct tokens

Trigger: a large playlist, streamed with transcoding (FLAC → mp3 192 kbps), where some of the tracks are already pre-cached. If I play a fully pre-cached playlist, there are no decision calls at all.

I’ll suggest a stable token to the SlimPing developer too. But the spec doesn’t require one, so Symfonium probably shouldn’t treat a new transcodeParams for the same track and format as a changed item. I can send the full debug log if it helps.

Device type

Phone

Media provider

Subsonic (Open)

Steps to reproduce

  1. Set app to always transcode
  2. Start a playlist
  3. disconnect Wi-Fi

Additional information

The SlimPing plugin for the Lyrion (formerly LMS) server is quite new. I try to help the dev to test it. More information on the plugin here: https://forums.lyrion.org/forum/user-forums/3rd-party-software/1821663-announce-slimping-an-opensubsonic-api-gateway-for-lms

I searched existing issues first

on

I understand that logs are mandatory

on

Log upload name / description

transcode-loop

I found your upload. It confirms 413 decision requests in about 2½ minutes, including requests after pause.

This matches a pre-cache feedback loop in 15.1.0. Preparing a future track publishes its new stream URL back into the queue, which triggers another preparation. The changing token exposes that loop.

A related pre-cache fix is included in 16.0 Beta 2. It should address this path, but I haven’t verified it with SlimPing. If you’re comfortable testing a beta, try it and let me know whether the requests stop while paused. Read the beta announcement in the release notes and APK instructions for how to get the official APK if Google Play hasn’t approved it yet.

If you prefer to stay on production, try setting playback pre-cache to 0 for mobile data, then clear and restart the queue.

First of all, thank you for the fast reply!

I just tried v16b2 and can confirm that it solves the issue.