su1s / e2m3u2bouquet

Enigma2 IPTV m3u parser and bouquet creator
GNU General Public License v3.0
68 stars 50 forks source link

Special meaning of "VOD.*" categories breaks bouquet creation #103

Closed oottppxx closed 5 years ago

oottppxx commented 5 years ago

This is a bug against v0.8.2 - didn't check v0.8.3 yet.

Helping someone, I've seen a stream with the following in the M3U: group-title="VOD | 24/7"

This breaks with "e2m3u2bouquet.py: KeyError(u'VOD | 24/7',)", and I tracked it down to line " cat_title_override = self._category_options[cat].get('nameOverride', '')" in save_map_xml.

I could make the error go away by changing either "cat.startswith('VOD -')" line immediately above to startswith('VOD') or by doing the inverse somewhere in parse_m3u.

However, there are quite a few number of these instances, and it's hard to know exactly which meaning each one has, as there's special meaning in seeing the string "VOD" in group-title and then also making "VOD -" as a special signal to the rest of the code; this shouldn't be done like it is, with the risk of stuff breaking (as in the example), but by setting some property on the category_options if we really want to handle VOD differently - don't use/overload category names for any signalling.

DougMac commented 5 years ago

Thanks @oottppxx. This is something I plan to tidy up in a future release.

DougMac commented 5 years ago

Although from an initial check it doesn't appear to be an issue in 0.8.3. I'll do some more tests.

Edit: Works for me in 0.8.2 as well. If you can provide a playlist (with usernames & passwords removed) with the issue I can use it as a test for any updates I do.

DougMac commented 5 years ago

Should be fixed in v0.8.4

oottppxx commented 5 years ago

Thanks! I ended up to being able to test it this evening but as it appears that the provider already renamed their bouquets to remove VOD, didn't reach any conclusion; I could setup an artificial test with an m3u file, but didn't really go to that trouble.