Closed misiek08 closed 1 week ago
š Thanks for opening your first issue here! š
If you're reporting a š bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can. To help make it easier for us to investigate your issue, please follow the contributing guidelines.
Thanks for the report! I wasn't able to reproduce but I think it would be interesting to know if the issue persists if the user overrides the "performance" setting of the browser.
Hello, have you found a solution yet? I'm facing a similar issue when playing an m3u8 link. When I switch to another tab, Video.js only requests the m3u8 file but doesn't request any TS files. It only makes the request when I return to the tab, but it shows a rather annoying loading screen. :(
The only solution we had is to detect muted player and just force src()
to reset whole player. Currently migrated to shaka, because video.js is getting worse every day, especially VHS was too unstable :(
Description
Setup basic live HLS+DASH player (I use it with DRM, but probably doesn't matter), start player muted and go to another tab. After 5+ minutes come back to this tab. Player will be downloading segments that passed and will report after while errors with each of the ABR playlists.
Looks very similar to https://github.com/videojs/http-streaming/issues/1196.
I think this is related to browsers killing chained timers in JS when tab is in background. Chrome is stopping such timers after 5 minutes by default. Probably global setInterval or requestAnimationFrame is a workaround.
I've tried plugin that is watching
visibilitychange
event and pausing player on leaving tab and then callingplay()
/currentTime(0)
after coming back to tab again - seemed like it works, but it only prolonged the issue to 10+ minutes.Sources
Doesn't matter, live HLS+DASH, with ABR should do.
Steps to reproduce
Explain in detail the exact steps necessary to reproduce the issue.
Results
Expected
Player still working correctly.
Error output
Additional Information
After returning to the tab player is downloading all old video segments (for a few seconds it tried to download audio, but after returning above errors it is just following video segments). I've tested
currentTime(0)
and nowliveTracker.seekToLiveEdge()
- they are not helping.videojs version
what version of videojs does this occur with? video.js 8.0.4
Browsers
Platforms
what platforms are affected? please include operating system and version or device and version for each
Other Plugins
are any other videojs plugins being used on the page? If so, please list them with version below.
Other JavaScript
are you using any other javascript libraries or frameworks on the page? if so please list them below.