dkaoster / scrolly-video

Components for scroll-based (or other externally controlled) playback.
https://scrollyvideo.js.org/
MIT License
971 stars 39 forks source link

Strange network behaviour for some videos #114

Open SudevKiyadaTR opened 3 months ago

SudevKiyadaTR commented 3 months ago

Hi there!

Been using the lib since past 3-4 months. We have observed a particularly strange behaviour with some of the videos in Svelte.

The page doesn't load up the video correctly while firing the URL on new tab. It receives multiple 304s but never loads up the video. The video loads up fine upon subsequent hard refreshes.

While this doesn't happen every time, I was able to narrow it down to some videos leading to this behaviour.

I would expect something like that for larger videos, but that was not the case during my inspection. Attaching one of such videos where I am facing the said issue.

https://github.com/user-attachments/assets/dbfbe070-90f3-4d96-87e2-e0b25f4a6fd1

Screenshot 2024-08-05 at 10 40 52 AM

Debug log console.log

SudevKiyadaTR commented 3 months ago

Update: If it helps, I was able to get it to load up fine by bumping up the timeout set in videoDecoder.js to close the decoder.

dkaoster commented 3 months ago

Hi @SudevKiyadaTR! I haven't seen this issue myself, but do you have minimal reproduction case of the code you're using? I am very curious about why this might be happening as well.

SudevKiyadaTR commented 3 months ago

Hey @dkaoster, created a sandbox here with a preview link here.

dkaoster commented 3 months ago

hi @SudevKiyadaTR I'm not able to see the 304s as you've mentioned. You're saying that it only shows up for certain videos and only with the svelte component? Does this error show up in the pure js version as well?