TODO list for release 0.5.11
This is meant for DEVELOPERS ONLY who want to help or discuss the current problems.
Urgent:
-
[ ] U-1. Merge https://github.com/z-huang/InnerTune/pull/1789
-
[ ] U-2. Improve the caching and fix the saved formats issue
-
Problem: https://github.com/z-huang/InnerTune/pull/1774#issuecomment-2567170386
-
Maybe steps to fix: https://github.com/z-huang/InnerTune/pull/1774#issuecomment-2566489335)
-
[x] U-3. || Update: fixed in https://github.com/z-huang/InnerTune/pull/1789 Fix normalization. The current clients do not provide the
loudnessDbanymore or a wrong/different value. This can lead to not working or inconsistent normalization. -
https://github.com/z-huang/InnerTune/pull/1774#issuecomment-2566174539
-
https://github.com/z-huang/InnerTune/pull/1774#issuecomment-2566560686
A possible fix to make such metadata consistent might be to make two requests to the player endpoint:
- One for metadata with the
WEB_REMIXclient (the$fieldsparameter could be used) - Another one for the streams with the
WEB_CREATORorIOSclient
Nice to have:
-
[x] N-1. || Update: added in https://github.com/z-huang/InnerTune/pull/1789 Add back the WEB_REMIX client for premium formats
-
[ ] N-2. Update the NewPipeExtractor dependency once they merge my PR: https://github.com/TeamNewPipe/NewPipeExtractor/pull/1253
-
[x] N-3. || Update: added in https://github.com/z-huang/InnerTune/pull/1789 Add some way to detect URLs which return 403 and try with another client
About loudnessDb, will be better to set it from adaptiveFormats when audioConfig its missing val loudness = body.playerConfig?.audioConfig?.normalizedLoudnessDb ?: format.loudnessDb?.toFloat()
About loudnessDb, will be better to set it from adaptiveFormats when audioConfig its missing val loudness = body.playerConfig?.audioConfig?.normalizedLoudnessDb ?: format.loudnessDb?.toFloat()
@th3y while this will get you some value for loudnessDb it is not a consistent one.
For example with the same song and same format you can get these responses:
WEB_REMIX:loudnessDb = -4.00IOS:loudnessDb = 2.00
Different clients can have different normalization targets which means the volume will be different depending on which client is used. This will not be a great user experience since users can get mixed volume targets and this defeats the purpose of normalization.
The only one of the current clients (the recent ones from my PR) which seems to provide the values as before is the WEB_REMIX one (which is the only YT Music one - the others are normal YT which has a different volume target).
So I guess the simplest fix would be to always use WEB_REMIX for metadata and the others only for the streams.
Also WEB_REMIX is the only client which provides premium formats. For these reasons I think the best fix (for both U-3 & N-1) might look like this:
- Make
playerrequest withWEB_REMIXand use metadata likeloudnessDbfrom this response - Try to play the best stream from that first request (because this can contain premium streams)
- If the stream url returns 403 fallback to other clients for the streams (but still keep using the metadata from the first request with
WEB_REMIX)
But for this to work there needs to be a way to detect if an url returns 403. @javdc had the idea to "do a HTTP HEAD request before returning the url to the player to see if it responds with a 200 or not" Idk if and for how long that would work.
An alternative which does not need 403 tests for now might look like this:
// make WEB_REMIX request - save metadata like loudnessDb from this one
if (user.isLoggedIn) {
if (user.hasPremium) {
// use streams from above WEB_REMIX request
} else {
// make another request with WEB_CREATOR and use these streams
}
}
// make IOS request and use these streams
But this could also break any moment so it might be better to do 403 tests somehow.
If we only talk about loudnessDb for now:
Another idea is to use the playerConfig.audioConfig.perceptualLoudnessDb because that seems to be the same across clients. But it provides different values again and users will end up with different volumes compared to the songs they played before. Maybe there can be something added to convert between loudnessDb <> perceptualLoudnessDb but I don't know if that is possible because of the way they are calculated.
Is this app going to be updated because it's my lifeline I'm to committed to it to switch
Is this app going to be updated
@finn-524 Nobody knows. Maybe it is dead. (I should have named this issue differently to not create false hope for a new release.)
Currently we have to wait for @z-huang to become active again. Could be tomorrow. Could be in years. Could be never.
Please do not ask about when or if there will be a new release here. This specific issue was meant for developers to discuss solutions to the problems only.
Good news: U-3, N-1 and N-3 are done: https://github.com/z-huang/InnerTune/pull/1789
Heckly good news: he went back online and did some management!!!