-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Register HttpPlugin for file:// for use in eg. electron #1222
Comments
A 1000 error is UNSUPPORTED_SCHEME. That means that we have no network plugin registered for the "file" scheme. I think our XMLHttpRequest plugin would work for it (assuming CORS doesn't become a problem, of course). Try running this code when launching your app: |
I currently have some minor issues with my application, but it seems to be working. |
If anyone tells me, where the registering happens, I can do a PR. |
@cromefire take a look at
|
I have a CL for that change waiting on review. |
Ok, we had a discussion about this internally, and decided to not make this an official part of Shaka Player. Browsers are our primary target, not Electron, and supporting requests to file:// would be inappropriate in a browser environment. |
The short version is: you can add this at the application level with one line after loading the Shaka library: shaka.net.NetworkingEngine.registerScheme('file', shaka.net.HttpPlugin); We aren't doing this in the library because |
Closes #1222 Change-Id: I5cb9dcb07d65d839aa4809faaea9bf2273c69c68
Cherry-picked to v2.3.1. |
Closes #1222 Change-Id: I5cb9dcb07d65d839aa4809faaea9bf2273c69c68
Cherry-picked for v2.2.10. |
Have you read the FAQ and checked for dublicates?: yesWhat version of Shaka Player are you using: jscdn from about one month agoCan you reproduce the issue with our latest release version: Unless someone implemented it, no and I don't think so, but I don't tested it.Can you reproduce the issue with the latest code frommaster
: same as aboveAre you using the demo app or your own custom app: A custom appIf custom app, can you reproduce the issue using our demo app: I can't test it in the demo app, because I use local files (but on a web server every thing works fine)What browser and OS are you using: Electron with node v8 on Ubuntu artfulWhat are the manifest and license server URIs: it is a local file generated by Shaka packager from an mp4, it has no protectionWhat did you do?I loaded the locally stored manifest (electron seemed to make file:// from it)What did you expect to happen?Shaka loads the manifestWhat actually happened?Shaka says, it can't load the manifest (1000)Edit
Shaka doesn't know by default how to handle file:// requests as use in for example electron. Please register it by default.
The text was updated successfully, but these errors were encountered: