Open maybeanerd opened 4 months ago
I'm going to try to adjust some things in the client experimentally to see if that would actually fix the entire issue - will need to first figure out where even to look If in the meantime a maintainer sees this, feel free to drop some extra info and context on this behavior please
first attempts seem to not break any existing behavior, but stop the problematic call from fetching all episodes: https://github.com/jellyfin/jellyfin-web/compare/master...maybeanerd:jellyfin-web:fix/playback-of-series-with-large-set-of-episodes
I have yet to test this with the 1000+ episode setup, though. Will do so soon™️ to ensure that this actually fixes the cause of the loading issue
Tested the solution, works! It fixes the issue for 1110 episodes. I'll open it as a PR, where I would hope someone who knows more about the system itself can check if this would break other existing behavior. I did try around everything I could think of and nothing seemed broken
This issue has gone 120 days without comment. To avoid abandoned issues, it will be closed in 21 days if there are no new comments.
If you're the original submitter of this issue, please comment confirming if this issue still affects you in the latest release or master branch, or close the issue if it has been fixed. If you're another user also affected by this bug, please comment confirming so. Either action will remove the stale label.
This bot exists to prevent issues from becoming stale and forgotten. Jellyfin is always moving forward, and bugs are often fixed as side effects of other changes. We therefore ask that bug report authors remain vigilant about their issues to ensure they are closed if fixed, or re-confirmed - perhaps with fresh logs or reproduction examples - regularly. If you have any questions you can reach us on Matrix or Social Media.
Still open. There were valid concerns with the PR I prepared but I haven't gotten to addressing them, since doing so needs a deeper dive into the APIs and application state. If anybody else wants to, feel free to take over. Otherwise I'll probably get to it at some point
Could actually be that https://github.com/Namo2/InPlayerEpisodePreview/pull/33 solved this issue? Could be a source of inspiration
How are your episodes structured? Are they all in one folder on the server or split by season?
It's ~1100 episodes split into 22 folders/seasons Most have < 100 episodes, some have more
Interesting. I have the same setup but don't experience this issue. I wonder if it's due to how your library is set up?
This is how mine's set up:
Can you trace the the request your client does when loading an episode? As mentioned in the original issue text, the request seems to not fail, instead it is a 200 that is probably cancelled due to a client side timeout.
Could be that your hardware is so much faster than mine that the timout doesn't hit?
In any case, I'll add back the content (removed tons of intermittent seasons for it to work) and see if I have the same issue with version 10.10.1 as well
I was still able to reproduce the issue, but in the PR that is linked to this issue, I think I now finally have provided a usable solution.
Can you trace the the request your client does when loading an episode? As mentioned in the original issue text, the request seems to not fail, instead it is a 200 that is probably cancelled due to a client side timeout.
Yep, I get a 1.83MB response which is truncated (I have ~100 fewer episodes than you do). It took 1.27s to fetch it.
Could be that your hardware is so much faster than mine that the timout doesn't hit?
Client I used for checking the above is Firefox + Windows 10 on a Ryzen 7 3700X machine with 16GB RAM but I also use the Android TV app on Chromecast with Google TV, the LG webOS app on an LG C2 TV and the iOS app on an iPhone 11.
Server is the official Docker image running on a NanoPi R6C running Armbian.
I just had a look at your PR and it seems there are some limitations with your new implementation though I'm not too familiar with the Jellyfin API or frontend but if there's any issues raised by the maintainers I can look into making the necessary API changes to expedite a better solution if needed.
Describe The Bug When starting an episode in a series with many episodes (e.g. one piece, 1110 episodes) the playback is stuck in the loading (before opening player) state forever. This behavior does not occur when I remove 800 of the 1110 episodes and try to play the exact same episode, so it seemed to be related to the amount of total episodes. This also happens on all episodes I tried, not only specific ones.
When digging deeper, I found that on server side, no errors are being thrown, but on client side, there is a request to get all episodes (https://jellyfin.cluster.diluz.io/Shows/cfe.../Episodes?IsVirtualUnaired=false&IsMissing=false&UserId=93d..&Fields=Chapters,Trickplay) which is huge. For one piece, it ends up being 2.4MB and takes quite some time to finish.
The client seems to be unhappy about the duration of the request, as it logs
Request timed out
although in the network tab, the request finishes with 200 (but maybe is stopped early by the client? the response is truncated)
Steps To Reproduce
Expected Behavior The episode should start playing (even if it takes long, which I would not expect, but tolerate)
Logs jellyfin.log
Screenshots This is what it will look like forever
System (please complete the following information):
Additional Context none