-
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
Player crash in Apache Cordova Applications when using cordova-plugin-network-information #4542
Comments
I think you could solve this by creating a custom ABR Manager based on the information available in |
Hi, @koenoe I agree this can be bypassed by adding a custom abr manager. However, for ease of use of Shaka Player, I think We need to have into account that this Cordova plugin intends to implement a polyfill for standard apis but it doesn't include |
It's the plugin's fault for exposing a half-complete version of the API, but a single "if" in Shaka isn't too bad. Please send a PR. Thanks! Also, please keep in mind that Cordova isn't part of our automated testing. So while we can't guarantee future compatibility ourselves, we are happy to have the community support the platforms it cares about. |
…removeEventListener in navigator.connection before using them fixes shaka-project#4542
Have you read the FAQ and checked for duplicate open issues?
Yes
What version of Shaka Player are you using?
3.3.9
Can you reproduce the issue with our latest release version?
Yes
Can you reproduce the issue with the latest code from
main
?Yes
Are you using the demo app or your own custom app?
Custom App
If custom app, can you reproduce the issue using our demo app?
Yes
What browser and OS are you using?
Android, iOS - Apache Cordova application
For embedded devices (smart TVs, etc.), what model and firmware version are you using?
Any
What are the manifest and license server URIs?
What configuration are you using? What is the output of
player.getConfiguration()
?Default
What did you do?
What did you expect to happen?
The playback starts
What actually happened?
The player crashes while loading the source. There is no much detail in error but it says
addEventListener
is not a function. This happens becausenavigator.connection
object provided by network information plugin of Apache Cordova doesn't include anaddEventListener
method. This can be solved by adding validation on simple_abr_manager.js to check if the method exists.The text was updated successfully, but these errors were encountered: