Bo Bayles
Bo Bayles
For what it's worth, I (original PR author) have switched away from this library - the advice in [the docs](https://github.com/closeio/ciso8601/blob/master/why_ciso8601.md#do-you-need-to-support-python--311) is correct; the Python 3.11+ `datetime.fromisoformat` is a suitable replacement,...
[Here](https://gist.github.com/bbayles/d4df156ecbd4a162f279ed2f8465124e) is a script for multi-threaded downloading of TS files from an M3U8 playlist.
This is [Elemental style](https://docs.aws.amazon.com/medialive/latest/ug/sample-manifests-hls.html), for what it's worth.
From the [README](https://github.com/globocom/m3u8#custom-tags): > This library ignores all the non-standard tags by default. If you want them to be collected while loading the file content, you need to pass a...
Try this code: ```python import m3u8 m3u8_text = """ #EXTM3U #EXT-X-INDEPENDENT-SEGMENTS #EXT-X-VERSION:5 #EXT-X-STREAM-INF:CLOSED-CAPTIONS=NONE,BANDWIDTH=2516370,AVERAGE-BANDWIDTH=2516370,RESOLUTION=1280x720,CODECS="mp4a.40.2,avc1.640020" video_720p.m3u8 #EXT-X-STREAM-INF:CLOSED-CAPTIONS=NONE,BANDWIDTH=1640580,AVERAGE-BANDWIDTH=1640580,RESOLUTION=960x540,CODECS="mp4a.40.2,avc1.640020" video_540p.m3u8 """ m3u8_obj = m3u8.loads(m3u8_text) nepali_audio = m3u8.Media(uri='audios/Nepali/master.m3u8', type='AUDIO', group_id='Audio', language='np', name='Nepali', default='YES', autoselect='YES') m3u8_obj.add_media(nepali_audio)...
For what it's worth, I think this type of parsing is far enough from RFC 8216 and its descendants to recommend using a different library.
This is fixed in https://github.com/globocom/m3u8/pull/340 , so I hope we can get that merged!
@mauricioabreu, are you open to the change in #340 now that version 4.0.0 is out?
These playlists are similar enough that I think you could just combine the text contents, but strip out the first three tags from the second one to avoid duplicating them....
As with [most other Python packages](https://docs.python.org/3/installing/index.html), installation is done with `pip`. To install the currently released version, do `pip install m3u8`. To install from a local copy, do `pip install...