synapse icon indicating copy to clipboard operation
synapse copied to clipboard

Media handler does not support HTTP range requests

Open matrixbot opened this issue 2 years ago • 9 comments

This issue has been migrated from #4780.


Presently, Synapse does not support HTTP range requests, which prevents users from seeking through audio/video media in many browsers. vector-im/element-web#2909 sought to fix this, though as that PR has been closed, I figured I should open another issue. This issue is the root cause of matrix-org/riot-web#4265.

matrixbot avatar Dec 16 '23 23:12 matrixbot

Hopefully the devs will fix this as soon as possible.

gmanskibiditoilet avatar Dec 30 '24 14:12 gmanskibiditoilet

hi @erikjohnston and @anoadragon453 can you please send out some devs to fix this synapse issue because many end-user matrix clients (e.g. Element, schildichat) are unable to seek video/audio media in many browsers and even the official desktop version of those end user clients due to the lack of HTTP range request support?

gmanskibiditoilet avatar Jan 18 '25 09:01 gmanskibiditoilet

Hi @gmanskibiditoilet. This issue is not on the team's immediate roadmap, but we'd be happy to review external contributions for it.

Given this likely isn't too complicated to implement, I've added the "Good First Issue" label to try and encourage new contributors to have a look at fixing this.

If anyone needs advice with implementing this issue, feel free to ask for help in #synapse-dev:matrix.org!

anoadragon453 avatar Jan 20 '25 10:01 anoadragon453

Hi @gmanskibiditoilet. This issue is not on the team's immediate roadmap, but we'd be happy to review external contributions for it.

Given this likely isn't too complicated to implement, I've added the "Good First Issue" label to try and encourage new contributors to have a look at fixing this.

If anyone needs advice with implementing this issue, feel free to ask for help in #synapse-dev:matrix.org!

great, hope you all will have external contributors forking this repo and launching multiple pull request to fix this issue. hav a nice day @anoadragon453

gmanskibiditoilet avatar Jan 20 '25 15:01 gmanskibiditoilet

any progress on fixing this problem? we have been waiting for it for soo long........... please note that this problem also exists in element desktop for windows, mac and linux as well. we have 3 machines running either of these OSes having element desktop installed and we found out that this issue persists in all of these 3 machines.

gmanskibiditoilet avatar May 19 '25 07:05 gmanskibiditoilet

any progress on fixing this problem? we have been waiting for it for soo long........... please note that this problem also exists in element desktop for windows, mac and linux as well. we have 3 machines running either of these OSes having element desktop installed and we found out that this issue persists in all of these 3 machines.

who has a PR please fix it and also mention here in this issue?

gmanskibiditoilet avatar May 28 '25 04:05 gmanskibiditoilet

@gmanskibiditoilet please don't comment on issues simply asking for them to get done. Either provide a PR yourself, or simply add a 👍 reaction to the issue.

anoadragon453 avatar May 28 '25 11:05 anoadragon453

This is espeically problematic for mp4s with the moov atom at the end of the file (as it usually is, especially from screen recordings and such.) Because of this, the entire file has to be downloaded before it can start playing. So you have to convert it to put the moov atom at the beginning with i.e. ffmpeg -i original.mp4 -movflags faststart -c copy new.mp4. If HTTP range requests were supported then the browser can request a piece of the end of the file to get the moov atom and start playing immediately.

Also if you are using chromium you are not able to seek the videos at all, even if it's already fully downloaded due to the moov atom being at the end. On firefox you can though.

ledlamp avatar Oct 07 '25 08:10 ledlamp

This is espeically problematic for mp4s with the moov atom at the end of the file (as it usually is, especially from screen recordings and such.) Because of this, the entire file has to be downloaded before it can start playing. So you have to convert it to put the moov atom at the beginning with i.e. ffmpeg -i original.mp4 -movflags faststart -c copy new.mp4. If HTTP range requests were supported then the browser can request a piece of the end of the file to get the moov atom and start playing immediately.

Also if you are using chromium you are not able to seek the videos at all, even if it's already fully downloaded due to the moov atom being at the end. On firefox you can though.

we agree with you, we hope this problem will need to be fixed asap.

xfst14 avatar Oct 31 '25 04:10 xfst14