-
Notifications
You must be signed in to change notification settings - Fork 791
Safari HLS playback results in error with overrideNative #1005
Comments
Thanks for reporting @kennypavan . Yeah, we haven't used overrideNative for Safari, and it seems there is an issue here. It definitely warrants further investigation. |
No problem. Thanks for your quick response @gesinger. |
I'm using exactly those three lines in Safari.
No errors in the console however still the native HLS is used , Same behaviour in Android Chrome |
This error on Safari 10.0.2, OSX 10.12.2
|
Guys, what is the status of this issue? test environment on my machine: |
+1 for @sbminimalistics: I'd like to know too, because I'd like to set the beforeRequest method in Safari too. Ain't possible right now (latest Video.js 6 release). :-( |
+1 for @sbminimalistics from my end too - seeing the issue on Safari 10, vjs version 5 and latest HLS. |
Discussed this issue today on the Videojs Slack channel. I'm also having a possibly related problem. One possible solution raised by the maintainers was to avoid using the html element This solution didn't work for me, but I'm on a different version of videojs and contrib-hls than the OP. It might be worth a quick try? |
Changing the source using an object like may also help with this problem: |
@gesinger Is there any update on this? I'm experiencing issues with Safari and overrideNative as well. Best. |
As far as I know there are no updates on this. |
Hey, The problem is just that you are getting the options wrong. This is how it should work like:
NOTE that the This isn't a bug, I got this working flawlessly with the above snippet. EDIT: Your Safari still needs to support MediaSource obviously, which is from Yosemite and above as far as I remember. EDIT: Note that mobile Safari does never support MediaSource |
Please check this test-page: http://tchakabam.com/test/2coders-videojs/ IMPORTANT: You need to press the "load" button to make sure videojs-hls initializes correctly with the desired config (not using native Safari HLS precisely). This behavior (needing to press load) is only on Safari, and it may be a bug that need to be investigated. However this example shows that generally the config can be applied to do this. We should probably close/rewrite this issue to what it really is. |
I can confirm that this issue still exists even with the options set right @tchakabam. |
Issue persists on and above iOS 11.2.1,videojs works perfect on and below iOS 11.0 What is the current status? |
Failed in
|
Confirming this is still an issue on the following versions, any updates on a solution in progress? : VideoJS videojs-contrib-hls Safari Errors [Error] TypeError: Attempted to assign to readonly property. |
Same issue |
same issue here. |
same issue |
Happening on Chrome Mobile, Edge Mobile and Edge desktop |
This happens when your video.js and contrib-hls.js are loaded after your video tag is already created. Put your js files before your video elements and everything works fine. |
Ran it in debug, seeing |
Debugged further, looks like MediaSource is undefined: |
@chaner regarding your comment on 14 Feb. The link you provided relates to iOS Safari, where Media Source is undefined. However, this issue affects the regular, desktop Safari on recent macOS, which has supported MediaSource for a while. Have I misunderstood you, perhaps? Apologies if so. |
Same issue |
Description
Attempting to play a HLS stream in Safari with overrideNative set true results in the errors listed below.
Steps to reproduce
Results
Expected
Video playback and HLS obj available.
Error output
TypeError: Attempted to assign to readonly property
TypeError: undefined is not an object (evaluating 'this.messageHandlers')
Additional Information
This appears to be a similar issue to #949 but setting the nativeAudioTracks and nativeVideoTracks to false did not solve the issue.
videojs-contrib-hls version
5.2.0
videojs version
5.17.0
Browsers
Safari v9.0.3
Platforms
OSX 10.11.3
The text was updated successfully, but these errors were encountered: