-
Notifications
You must be signed in to change notification settings - Fork 32
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
Protocol Handler: WEBM does not load when used in video HTML tag #57
Comments
27 tasks
Well only after running it myself I did noticed that warning in the console actually explicitly mentioned it could not match content type. |
As I suspected it's the same issue as #54 as this change loads the video diff --git a/demo/protocol/protocol.js b/demo/protocol/protocol.js
index 4f88087..8270bf3 100644
--- a/demo/protocol/protocol.js
+++ b/demo/protocol/protocol.js
@@ -50,6 +50,7 @@ browser.protocol.registerProtocol("dweb", request => {
}
case "dweb://html/video.webm": {
return {
+ contentType: "video/webm",
content: (async function*() {
const response = await fetch(
"https://ipfs.io/ipfs/bafybeigwa5rlpq42cj3arbw27aprhjezhimhqkvhbb2kztjtdxyhjalr3q/big-buck-bunny_trailer.webm", I'm closing this as being duplicate of #54 |
Gozala
added a commit
to Gozala/libdweb
that referenced
this issue
Aug 8, 2018
In some cases like <video /> starting request with unkown mime type cancels the channel. To avoid that, unless we know the content type we wait for the first chunk to detect contentType before starting request. Fix mozilla#57
Just for the record, retested it with async API and works as expected, thanks! |
3 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Summary
WEBM video fails to load on initial load when used in
<video>
tag.If opened directly at least once, then loads fine.
Discovered this problem in IPFS Companion, which was streaming videos from IPFS,
but I created a simplified repro without IPFS that downloads file via HTTP and produces the same error.
Tested with 2MB and 22MB files, same result for both. Steps below use 2MB file.
How to Reproduce
Run
demo:protocol
from myvideo-render-bug-demo
branch:Open
dweb://html/
first: loading via<video>
tag will fail with this error.Open
dweb://html/video.webm
directly: it will load and play just fine.Open
dweb://html/
again: loading via<video>
tag will work this time.Open
dweb://foo/
: loading via<video>
tag from different origin will fail.The text was updated successfully, but these errors were encountered: