-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Buffering Bug #163
Comments
Also affects:
With or without MPEG-DASH, same effect. |
I have what sounds like the same issue on an NVidia Shield running Kodi 19.1. It seems fairly random and I'm not using playlists, but every couple of videos I try to play buffers to the point of being unwatchable. If I stop the video and start again a few times eventually it runs fine. |
Can confirm this too. |
Also affects:
Restarting the videos doesn't fix it for me, it just ends up buffering in pretty much the same spots, within a few seconds it. However, restarting Kodi (via systemctl restart kodi) does clear the issue. |
Here is a snippet of a log, a much much larger log spanning ~20 hours is available. It shows the video playing just before fine at 08:04, and then the stuttering/buffering happening on the video starting at 08:16 https://paste.ubuntu.com/p/RzRFzcYhQS/ I also tried to restart the same video, and pretty much buffers in the same exact spots. Restart kodi, and video plays fine. |
I can also confirm restarting videos doesn’t fix the buffer issue. Only a Kodi device restart or clearing database and cache from Kodi YouTube Add-on settings. To elaborate on my original post it doesn’t only occur to videos in a playlist. After a Kodi restart I haven’t had the first video I opened buffer, usually after watching several. In this YouTube Add-on settings I changed the cache size and video settings to every available option yielding the same result with this buffering bug still persisting. |
This occurs also if I send videos from other devices via html POST to play queue. And is independent to settings of cache in advancedsettings.xml Add-on Version: 6.8.15 and 6.8.14 and 6.8.13 |
Can also confirm this issue. I always use POST for playing multiple videos in queue. Restarting the video doesn't work for me either only a Kodi restart. Add-on Version: 6.8.15 |
Same issue for me, happens randomly, it can happen immediately or after playing a few vids. I can fix it without a restart by turning off MPEG DASH if it's on or turn it on if it's off. ADD-on Version: 6.8.15 |
I've been looking around some more and I think this issue may be down to YouTube throttling on their side. If you read the youtube-dl reddit forum they seem to be aware of throttling being done by Youtube now, I also tested myself downloading a list of videos with youtube-dl and the first few start downloading at 2mbps+ then drops to 50kb/s. Not sure what triggers the throttling yet though. I think it then stops throttling after a short time, so perhaps just by exiting Kodi and restarting it allows enough time for the throttling to have stopped. |
This comment is interesting, it is suggesting that there is a "n" query parameter that YouTube is putting this parameter in their URLs and the client-side needs to modify it and send it back as a signature/challenge of some sorts. ytdl-org/youtube-dl#29326 (comment) |
Yea they seem to have the fix but no one has had time to implement it yet. Hopefully the fix works and can be added here as well. |
Translator: RPi4, LibrELEC 9.95.4, Kodi 19.1, YouTube 6.8.15+matrix.1 |
The https://github.com/yt-dlp/yt-dlp/blob/master/yt_dlp/extractor/youtube.py |
This has been plaguing me now for months and I've tried YouTube addons 6.8.10 -15, from repos and downloads, Libreelec 9.2.6, 9.2.8 and 10.1, Odroid C2, C4 and Raspberry pi 4 (all buffer even 1080 at 30fps) and upgraded my network to a i5 pfsense and cat6 cabling, nothing worked. I think there are 2 issues here:
Downloading videos from these channels with youtube-dl (on x86 Ubuntu), yields similar download speeds to other videos. Here I think google is throteling somehow... Also, is it just my YouTube addon, that only buffers a few seconds and gets cleared everytime I scrub or play/pause? So I can't just wait for it to buffer, since the buffer resets when I click play, or go back 10 seconds... I've played with the buffer size in the add-on settings and I have an advanced settings file for buffering everything to 400mb on a RPI4 2gb, which all other local/online videos respect, just not the YouTube add-on. |
Someone from Pytube generously wrote the functions needed to parse and generate the "n" token: https://github.com/pytube/pytube/blob/master/pytube/cipher.py |
I've created an alpha build with this included, https://github.com/anxdpanic/plugin.video.youtube/releases/tag/6.x.x-dev |
Thanks for the new build! While I'm not skilled enough to contribute code, I can at least test it. I've installed it on my main system and will see how it behaves over the next few days. I hope others will do the same. |
alpha1 didn't fixed the bug - still endless buffering after 3-4 videos |
Tested the alpha build - it seems that the videos are starting faster now, but I still got the buffering issue twice in 20-25 videos. It might be less often than before, but I am not sure about this - need more tests. |
Almost the same here, but number of videos smaller, from 3 to 7 оn average |
Unfortunately the buffering did not go away and still persists same as before. After a few videos at random it will start buffering to unwatchable conditions. Thank you for your attempt. |
Just as an update to the Alpha build I believe it may have at least done something. If a video starts buffering I can stop and reopen it and it’ll play fine. Before I had to restart Kodi to get the same video exhibiting buffering to play normally. |
@neo-neo1, if that's the behaviour, then it works for me like this for a very long time. I'm currently on 6.8.16+matrix1 version, but it's been a few months like this. Sometimes i get the buffering as soon as i start a video, but most of the time it is enough to stop and start it again. Sometimes 2-3 times, sometimes with a small, couple seconds delay, and it plays fine then. I never had to restart Kodi as a whole to get it played correctly. It behaves like this for me on Shield TV, as well as a on Linux based PC i'm using. I haven't tried it on Windows at all. |
Version 6.8.17 fixed this problem for me. |
6.8.17+matrix1 still not working for me unfortunately, buffering still happen occasionally. |
alpha6 works perfectly on leia! |
6.8.18 alpha6 fixed the buffering issue for me under LibreELEC 9.2.8 Rpi4 version. Very big thanks to the devs! |
@toupeira thks man, it works. |
Guys,thank you very much for the fix,working perfectly!!;) |
Installed the latest alpha release for Leia – 6.8.18.alpha6 (https://github.com/anxdpanic/plugin.video.youtube/releases/download/6.x.x-dev/plugin.video.youtube-unofficial-6.8.18.alpha6.zip), it worked, but only for the first video played. After that, the original problem with no buffering is back, making videos unplayable. |
@Drag0nFly if you try the same video at the exact same quality level, on either the official YT site or app, do you also get the buffering? Just to rule out the occasional slow network day |
Yes, I did that. Once the issue occurs, videos do not play due to zero buffering. This is running off a dedicated fibre connection, so I can safely rule out intermittent connection isues (the bitrate for these streams are so low anyway that it would make little difference) Obviously in a standalone browser none of these issues occur, just on Kodi using the plugin. I did however restart the Kodi (18.7) instance a couple of times and re-tested, and witnessed the same problem after the first few restarts. Later, when I tested the videos after another restart they did play, although I only tested 2-3 of them due to time constraints. Not sure what to make of it, but will let you know if it re-occurs when I test it later today (and look for any hints in the debug log, if anything logs to it) |
When's this being pushed to the repo. such a frustrating bug, glad its fixed. |
6.8.18 should be available from the official repository already. |
I mean the kodi repository not github. |
Thanks, refreshing the repo now reports .18 instead of .17 updated. |
@anxdpanic i hope i can install the final .18 unofficial version for your panicked repo :) |
Disable "Yatse Kodi helper script" under program add-ons if still does not work |
Thank you @anxdpanic for 6.8.18, it fixes the issue. THANK YOU, it was VERY frustrating. Please set up donations, I owe you a few euros and so does everyone else in this thread. |
Well then. Another data point: I installed the 6.8.18 version a month or so ago, and it r̶e̶s̶o̶l̶v̶e̶d̶ squashed the bug. And then this evening, the bug unsquashed itself...or so it appeared Dammit. Turns out my wireless AP range extender, which feeds my kodi box, needed to be rebooted. But before I did that, I ran SpeedTest on my kodi box, confirming that it wasn't 6.8.18 that was misbehaving, thank the Maker. Cheers! |
Looks like the "Buffering Bug" is back. I'm trying to watch a video right now, but the old symptoms are back. Vers: 6.8.18 |
@Killom does this happen with other videos? Do you have the IDs or names of one or more videos that have this problem? Does playing the same video on the browser / official app have the same problem? |
@RNavega Same with every other video I'm trying to start Example: zoCK3vMcZ-M Running fine on Browser / YT App Edit: .. will post logs |
@Killom thank you. For me, on plugin.video.youtube that video is playing normal in either 1080 HD with Mpeg-DASH playback or 720HD with normal playback, and it caches a few seconds ahead too. If it didn't play well on your browser or app then we could call it as a slow day on your connection, but since you said it plays fine in the official channels over there and I can't reproduce here on Kodi, then I have no idea =( |
https://pastebin.com/CaA2YHWb Dunno if its just me ... |
Ok, was just me ... Looks like HDMI cable/interference was the cause here. (Using 4B model) Had very bad WiFi Rx/Tx. Switched to higher channels on Router - Problem gone. Serious gourmet shit :D |
Good ol' root cause analysis for the win ;) |
@Killom i have watched alot of video until 5 minutes ago..... all streamed whitout any issue. |
Several people have all recently reported this same issue at Kodi forums - YouTube Addon (last page). This is a reproducible problem. When playing videos from a playlist after 2-3 videos the next video that starts will buffer every several seconds.
I’m able to open a new video that won’t buffer but If I go back to the previous video which had buffering issues it will always have buffering issues unless I restart Kodi device or delete cache and database from YouTube addon settings.
This is not a network or device issue.
Edit: (Additional detail) It doesn’t only happen to videos in a playlist. Usually after watching several videos at random as well. After a Kodi restart I haven’t had the first video I opened buffer, usually after watching several.
In this YouTube Add-on settings I changed the cache size and video settings to every available option yielding the same result.
Been using this Addon since 1.0.
The text was updated successfully, but these errors were encountered: