[mythtvnz] Blank characters at start of titles in EPG

Stephen Worthington stephen_agent at jsw.gen.nz
Mon Oct 17 12:12:21 BST 2016


On Mon, 17 Oct 2016 22:26:38 +1300, you wrote:

>On Mon, Oct 17, 2016 at 7:43 PM, Stephen Worthington
><stephen_agent at jsw.gen.nz> wrote:
>> On Mon, 17 Oct 2016 17:44:04 +1300, you wrote:
>>
>>>Hi,
>>>
>>>These all have "All New " in front for me (using tv_grab_nz-py),
>>>except possibly repeats which have the normal titles. I don't do any
>>>post processing. Something isn't removing "All New" and not removing
>>>the trailing space on your end?
>>>
>>>All New Dr. Ken
>>>All New Mike & Molly
>>>All New The Big Bang Theory
>>>All New 2 Broke Girls
>>>All New The Middle
>>>
>>>Duke has "New: " just to be different. And of course "New Girl" is valid.
>>
>> Where are you getting your EPG from?  The downloaded EPG does have
>> processing to remove the "All New " bit, but I think it does not
>> handle "All New: " and definitely does not handle "New: ".  What I
>> have done is to do postprocessing on my database after
>> mythfilldatabase has been run.  This is what I currently have in my
>> epg_fixes.sh script:
>
>epg.org.nz/freeview.xml.gz
>
>I haven't touched this in a couple of years and may way well have
>something out of date and/or missing, but if I download the XML and
>take a look I see:
>
>    <programme channel="tv2-plus1.freeviewnz.tv" start="20161018203000
>+1300" stop="20161018210000 +1300">
>        <title>All New The Middle</title>
>        <sub-title>New Season</sub-title>
>        <desc>S8 E1 Our favourite family from Orson, Indiana are back
>for an 8th season! In the season premiere Frankie and Mike prepare to
>meet April - the love of Axl's life.</desc>
>        <episode-num system="dd_progid">10454729</episode-num>
>        <subtitles type="teletext" />
>        <rating system="Freeview">
>            <value>PGR</value>
>        </rating>
>
>I've not seen "All New" get removed in the source.

It is supposed to be, but as I am now doing my own fixes, it is a bit
hard to check.

>> #!/bin/bash
>>
>> ##############################################################################
>> # epg_fixes.sh
>
>> select chanid,starttime,title,subtitle,programid from program where
>> title like 'All New %';
>> update program set title=substr(title,8) where title like 'All New %';
>
>Shouldn't that be:
>
>update program set title=substr(title,9) where title like 'All New %';

Thank you, it was a bug in my code causing the problem with the blank
characters.

>And another select and update for 'All New: %'? Not sure I've noticed
>that syntax in the RPG but if not now then surely we'll see it in
>time.

Yes, it probably should be added to the list.

>Thanks for the script, I'd been thinking about tidying up some of this myself.
>
>> If anyone wants a copy, I have it on my web server at:
>>
>>   http://www.jsw.gen.nz/mythtv/epg_fixes.sh
>>
>> Most of the fixes are obvious, but the Joanna Lumley one is for a bad
>> programid value that tells MythTV that all the episodes are the same
>> episode, when in fact there is a new episode weekly.  Without that
>> fix, the duplicate detection was using the programid and saying they
>> all matched, when the description was changing each week.

I have updated the script on my web server.



More information about the mythtvnz mailing list