Skip to content
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

Getting MEDIA_SOURCE_OPERATION_THREW Error #7977

Closed
bhargavnaidu22 opened this issue Jan 29, 2025 · 5 comments · Fixed by #8077
Closed

Getting MEDIA_SOURCE_OPERATION_THREW Error #7977

bhargavnaidu22 opened this issue Jan 29, 2025 · 5 comments · Fixed by #8077
Assignees
Labels
component: HLS The issue involves Apple's HLS manifest format platform: WebOS Issues affecting WebOS priority: P2 Smaller impact or easy workaround type: bug Something isn't working correctly
Milestone

Comments

@bhargavnaidu22
Copy link

Have you read the FAQ and checked for duplicate open issues?
✔ Yes

If the problem is related to FairPlay, have you read the tutorial?
N/A

What version of Shaka Player are you using?
📌 "shaka-player": "4.11.0"

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?
🖥 Browser: Chrome 132.0.0.0
🖥 OS: WebOS

For embedded devices (smart TVs, etc.), what model and firmware version are you using?
📺 Device: LG WebOS TV
📜 Firmware Version: Varies

What are the manifest and license server URIs?
🎥 Manifest URI:

https://stream-us-east-1.getpublica.com/playlist.m3u8?network_id=4608&live=0&avod=1
(Let me know if you prefer to share this privately.)

📜 License Server URI: (If applicable)

What configuration are you using? What is the output of player.getNonDefaultConfiguration()?
📌 Configuration:

{
"streaming": {
"bufferBehind": 30,
"retryParameters": {
"maxAttempts": 5,
"baseDelay": 1000
}
}
}
(Provide the actual configuration output from your console if different.)

What did you do?

Loaded an HLS stream with Shaka Player 4.11.0
Tried playing on LG WebOS / Vizio Smart TV
Encountered the following error:
Shaka Error MEDIA.MEDIA_SOURCE_OPERATION_THREW
(NotSupportedError: Failed to execute 'addSourceBuffer' on 'MediaSource':
The type provided ('binary/octet-stream; codecs="avc1.64001f"') is unsupported.,
The mediaSource_ status was open expected 'open')
What did you expect to happen?
✅ The video should play without issues.

What actually happened?
❌ Playback fails with the error:
MEDIA.MEDIA_SOURCE_OPERATION_THREW (NotSupportedError: Failed to execute 'addSourceBuffer' on 'MediaSource')

Are you planning to send a PR to fix it?
🤔 Not at the moment.

Possible Causes & Fixes
🔹 Codec Issue:

avc1.64001f may not be supported on your device.
Try changing the codec to a more compatible one (avc1.4d001e or avc1.42E01E).
Run MediaSource.isTypeSupported('video/mp4; codecs="avc1.64001f"') in the browser console to check compatibility.
🔹 Incorrect mediaSource_ State:

The MediaSource might not be in the correct open state when adding a buffer.
Ensure MediaSource.readyState === "open" before calling addSourceBuffer().
🔹 HLS Playlist Issue:

Check if the .m3u8 file provides alternate codec options.
Test the stream in Shaka Player Demo App to confirm if it's a player-specific issue.
🔹 Workarounds to Try:

Use the hls.js library instead of Shaka for testing.
Transcode the content using FFmpeg to a more widely supported codec.
Upgrade to the latest Shaka Player version if available.

@bhargavnaidu22 bhargavnaidu22 added the type: bug Something isn't working correctly label Jan 29, 2025
@avelad avelad added the platform: WebOS Issues affecting WebOS label Jan 29, 2025
@shaka-bot shaka-bot added this to the v4.14 milestone Jan 29, 2025
@avelad
Copy link
Member

avelad commented Jan 30, 2025

Loaded an HLS stream with Shaka Player 4.11.0
Tried playing on LG WebOS / Vizio Smart TV
Encountered the following error:
Shaka Error MEDIA.MEDIA_SOURCE_OPERATION_THREW
(NotSupportedError: Failed to execute 'addSourceBuffer' on 'MediaSource':
The type provided ('binary/octet-stream; codecs="avc1.64001f"') is unsupported.,
The mediaSource_ status was open expected 'open')

binary/octet-stream; codecs="avc1.64001f"?? binary/octet-stream? sure? It should be video/mp4 for example....

@avelad avelad added the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jan 30, 2025
@bhargavnaidu22
Copy link
Author

This is the URL that we put in the player
https://stream-us-east-1.getpublica.com/playlist.m3u8?network_id=11090&live=0&avod=1&cb=[CACHEBUSTER]&u=https://ssai.gumgum.com/gs/stream/master/invincible/content.m3u8?stream_url=https%3A%2F%2Fcontent.uplynk.com%2F2ec6135d52a84a10ba125982da509d2f.m3u8& &did=[DID]&app_bundle=[APP_BUNDLE]&app_name=[APP_NAME]&app_domain=[APP_DOMAIN]&app_category=[APP_CATEGORY]&app_store_url=[APP_STORE_URL]&preroll=1&preroll_duration=120&ad_breaks=00:00:00,00:01:00,00:04:00&pod_duration=[POD_DURATION]&content_genre=[CONTENT_GENRE]&content_language=[CONTENT_LANGUAGE]&content_title=[CONTENT_TITLE]&ua=[%UA%]&ip=[IP]&device_type=[DEVICE_TYPE]&gdpr=[GDPR]&ifa_type=[IFA_TYPE]&is_lat=[LIMITED_AD_TRACKING]&player_height=[HEIGHT]&player_width=[WIDTH]&content_keywords=[CONTENT_KEYWORDS]&min_ad_duration=6&max_ad_duration=120&content_rating=[CONTENT_RATING]
The above URL is the from Publica after stiching SSAI ads when pass our HLS stream to Publica.
We get the error mentioned in this thread when we use this ad inserted URL. Please suggest what we need to look into and what needs to be done to resolve this issue

@shaka-bot shaka-bot removed the status: waiting on response Waiting on a response from the reporter(s) of the issue label Jan 30, 2025
@bhargavnaidu22
Copy link
Author

Hey @avelad, Can you please look into the above-mentioned Issue at the earliest.

@avelad
Copy link
Member

avelad commented Feb 5, 2025

Sorry I don't have WebOS to test :(

@bhargavnaidu22
Copy link
Author

It can be verified on normal browsers as well

avelad added a commit to avelad/shaka-player that referenced this issue Feb 13, 2025
@avelad avelad added the priority: P2 Smaller impact or easy workaround label Feb 13, 2025
@avelad avelad self-assigned this Feb 13, 2025
@avelad avelad added the component: HLS The issue involves Apple's HLS manifest format label Feb 13, 2025
@avelad avelad closed this as completed in d4ecdad Feb 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: HLS The issue involves Apple's HLS manifest format platform: WebOS Issues affecting WebOS priority: P2 Smaller impact or easy workaround type: bug Something isn't working correctly
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants