Videos on Instagram looping to start skips first 5 seconds of video
Categories
(Web Compatibility :: Site Reports, defect, P2)
Tracking
(Webcompat Priority:P2)
| Webcompat Priority | P2 |
People
(Reporter: tnikkel, Unassigned)
References
()
Details
(Keywords: webcompat:contact-ready, Whiteboard: [webcompat:sightline])
User Story
platform:windows,mac,linux impact:feature-broken affects:all
- Use a fresh profile on latest nightly.
- Login to an instagram account (needed so that the video loops instead of stopping after one play).
- Visit https://www.instagram.com/p/CvVGxTdpItC/ and play the video with audio.
- Wait until the end, it will loop around to the start.
- Except it doesn't start from the start, it skips ahead like 5 seconds.
I reported this because I see many video glitches on instagram that don't happen in other browsers, but this is the first one I've gotten consistent steps to reproduce.
I can reproduce as far back as 2020-06-30. Before that the video does not play at all, the progression range for the video going from not playing to playing (ie NOT this bug) is https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=9b981fcfb6ac3119837605e3189c5832446c77ab&tochange=ca79c56a0a1b6fcbf823ee46973951b133a73a0c in case that's useful.
Comment 1•2 years ago
•
|
||
Loading the video https://scontent.cdninstagram.com/v/t66.30100-16/10000000_1056345822439883_7722720021638499092_n.mp4?_nc_ht=instagram.fwlg1-2.fna.fbcdn.net&_nc_cat=111&_nc_ohc=CcnvdjjTbOoAX8Z3w9p&edm=AP_V10EBAAAA&ccb=7-5&oh=00_AfDzJ76xZakPm99mRpx1pJpHZ8mJc6DHPqIUeFOMaOQmXA&oe=64D1AFBE&_nc_sid=2999b8 directly, and setting document.getElementsByTagName("video")[0].loop = true in the Web Console leads to the video looping from the beginning (before the 1 second mark at least).
Similarly for using the Web Console to set loop when not logged in https://www.instagram.com/p/CvVGxTdpItC/ .
I haven't created an instagram account to test the instagram player's mechanism of looping.
| Reporter | ||
Comment 2•2 years ago
|
||
I'd encourage you to try with a logged in account.
When you are logged out the video element has a https url, and if you use inspector to delete some elements so that you can right click the video and turn on looping, then the problem does not appear.
If you log in then the video element has a blob url. So it seems as though it's a completely different scenario.
Comment 3•2 years ago
|
||
Instagram is probably pretty important to have a decent experience with.
I know at least one person who uses Chrome to open Instagram because the experience is bad in Firefox.
Updated•2 years ago
|
Comment 4•2 years ago
|
||
I can't reproduce this issue on the latest Nightly 119.0a1 (2023-09-01) on Windows 11. That video loops well without any problem for me. (viewing via a logged account) Would you mind to capture a profiled result and share the link to us?
Thank you!
| Reporter | ||
Comment 5•2 years ago
|
||
I get an error when I try to upload the profile (perhaps because it is too large?), so I downloaded it and put it on google drive
https://drive.google.com/file/d/10e82Yr3bwOLSS5no5uLIKMOpAc8o59e-/view?usp=sharing
| Reporter | ||
Comment 6•2 years ago
|
||
I tried to reproduce on Win10 (I originally saw this bug on macOS, and where the profile above was recorded), it does reproduce there, but not as frequently. On macOS the bug happens 90%+ of the time, on Windows probably under 50%.
Updated•2 years ago
|
Comment 7•2 years ago
|
||
Sorry for my late reply, I've checked the profiled result in the comment 5, and this issue is not related with looping at all, the media element isn't even set to loop=true. The looping logic is controlled by Instagram, they listen to ended event to seek the video to 0 manually. The real problem here is missing MSE data.
From this simpiled profiled result, you can see the video data got evicted for [0-5] and [5-10]. I guess we reached the limit of video data, so it triggered the data eviction algorithm. In theory, whenever the buffered range changes, Instagram should monitor that range and determine whether they need to append more data.
In this case, as we no longer have data in [0-10], when Instagram asks us to seek to 0, we couldn't do that. As they didn't even re-append those video data again, it turned out that we became seeking to the first available frame, which is at 10s, not 0s.
As I'm still not able to reproduce this issue on both my OSX and Windows, could you help me capture the profiled result again with MOZ_LOG=HTMLMediaElement:5,HTMLMediaElementEvents:5,MediaSource:5,MediaSourceSamples:5,MediaDecoder:5,MediaFormatReader:5 to allow me to confirm if my assumption is correct or not?
From above analysis, I'm more tend to believe this is Instagram's issue, because website should be responsible for maintaining the correct data buffer. But it would be great to get another profiled result and confirm it again.
Thank you!
Updated•2 years ago
|
| Reporter | ||
Comment 8•2 years ago
|
||
Let's move it to web compat, maybe we can get instagram to fix it.
Updated•2 years ago
|
Updated•2 years ago
|
Comment 9•1 year ago
|
||
Tim can you still reproduce this when logged in? I couldn't when I tried now.
Updated•1 year ago
|
Updated•1 year ago
|
Comment 10•1 year ago
|
||
I can't reproduce this anymore, and I can't find recent reports about something similar. For now, I'll close this as worksforme.
Description
•