add-ons / add-ons/plugin.video.vrt.nu
Some streams fail with "415 Unsupported Media Type"
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 125
- Forks
- 27
- Avg merge
- 3h 46m
- Merged PRs (30d)
- 12
Description
Describe the bug
There is an outstanding issue at VRT NU where some episodes do not work when using HLS streams (i.e. when not using Widevine). The problem has been reported a few times to VRT and they have confirmed this general issue. In most cases they will fix the faulty stream by hand when reported, but the root cause is yet unknown and unfixed.
This relates to #308, #311 and #538
To reproduce
Steps to reproduce the behavior:
- Disable Widevine (and restart the add-on)
- Go to program 24 hours in police custody
- Click on episode S04E05
- See error 415 Unsupported Media Type
Fix
- Verify this issue on the VRT NU website (Apple Safari?) or in the VRT NU app (Iphone/Ipad?)
- Report the stream to VRT NU at: https://www.vrt.be/vrtnu/help/
- Do mention the error "415 Unsupported Media Type" and it is related to the HLS stream only.
- Wait for VRT to fix the stream.
Work around
Enable Widevine in the settings so the VRT NU add-on selects te MPEG-DASH stream that is unaffected by this issue.
Additional context
- Operating system: LibreELEC 9.0.2
- Kodi version: Leia 18.2
- Addon version: 1.10.0
- Using a VPN: no
- Country you are using the addon from: Belgium
Log (if available)
This is an example log from an earlier identical issue.
2019-06-14 02:24:56.218 T:1321550704 NOTICE: [plugin.video.vrt.nu] Got cached token '/storage/.kodi/userdata/addon_data/plugin.video.vrt.nu/ondemand_vrtPlayerToken.tkn'
2019-06-14 02:24:56.219 T:1321550704 NOTICE: [plugin.video.vrt.nu] URL get: https://media-services-public.vrt.be/vualto-video-aggregator-web/rest/external/v1/videos/pbs-pub-cd09cc3c-5178-49c1-9387-715cb9ad98ff$
vid-d0b7cfaa-fd96-448e-9923-281b10261bfa?vrtPlayerToken=b10@b04c02c93691e93774a02025a289e44ce86e4ef8fc3f9d567d427964d37a1c4c&client=vrtvideo
2019-06-14 02:24:56.466 T:1321550704 NOTICE: [plugin.video.vrt.nu] URL get: https://remix-cf-vrt.akamaized.net/remix/18f7b87b-2715-490c-9ac6-8f05fbf5c7e4/remix_aes.ism/.m3u8?hd
2019-06-14 02:24:56.655 T:1321550704 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <class 'urllib2.HTTPError'>
Error Contents: HTTP Error 415: Unsupported Media Type
Traceback (most recent call last):
File "/storage/.kodi/addons/plugin.video.vrt.nu/addon.py", line 13, in <module>
router.router(sys.argv)
File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/router.py", line 70, in router
_vrtplayer.play(params)
File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/vrtplayer.py", line 222, in play
stream = _streamservice.get_stream(params)
File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/streamservice.py", line 245, in get_stream
stream = StreamURLS(*self._select_hls_substreams(manifest_url))
File "/storage/.kodi/addons/plugin.video.vrt.nu/resources/lib/streamservice.py", line 276, in _select_hls_substreams
hls_playlist = urlopen(master_hls_url).read().decode('utf-8')
File "/usr/lib/python2.7/urllib2.py", line 154, in urlopen
File "/usr/lib/python2.7/urllib2.py", line 435, in open
File "/usr/lib/python2.7/urllib2.py", line 548, in http_response
File "/usr/lib/python2.7/urllib2.py", line 473, in error
File "/usr/lib/python2.7/urllib2.py", line 407, in _call_chain
File "/usr/lib/python2.7/urllib2.py", line 556, in http_error_default
HTTPError: HTTP Error 415: Unsupported Media Type
-->End of Python script error report<--
2019-06-14 02:24:56.679 T:1937156496 ERROR: Playlist Player: skipping unplayable item: 0, path [plugin://plugin.video.vrt.nu/?publication_id=pbs-pub-cd09cc3c-5178-49c1-9387-715cb9ad98ff&action=play&video_id=vi
d-d0b7cfaa-fd96-448e-9923-281b10261bfa&video_url=https%3A%2F%2Fwww.vrt.be%2Fvrtnu%2Fa-z%2Fappel-d-urgence%2F2%2Fappel-d-urgence-s2a1%2F]
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in resources/lib/streamservice.py at _select_hls_substreams, where the logged 415 occurs while fetching the HLS playlist. Reproduce with Widevine disabled using 24 hours in police custody, S04E05, then verify the stream on VRT NU and report the HLS error to VRT. Done means VRT has fixed the faulty stream; Widevine is the documented workaround meanwhile.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- audio-video-rtc, backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100