[mythtvnz] tv_grab_nz-py configuration issues

Stephen Worthington stephen_agent at jsw.gen.nz
Thu Dec 5 03:18:04 GMT 2013


On Thu, 5 Dec 2013 15:21:25 +1300, you wrote:

>On Thu, Dec 5, 2013 at 1:49 PM, Stephen Worthington
><stephen_agent at jsw.gen.nz> wrote:
>> On Thu, 05 Dec 2013 09:32:32 +1300, you wrote:
>>
>>>On 05/12/13 09:26, Nick Rout wrote:
>>>> channel=tv1.freeviewnz.tv
>>>> channel!chinesetv.freeviewnz.tv
>>>>
>>>> Where = signifies you want that data, ! signifies that you don't.
>>>> However, as I say I am not sure that is the exact syntax until I get
>>>> home and look at the file there.
>>>
>>>That is correct, you only really need the = lines, not having a line is
>>>basically the same as having a ! line.
>>>
>>>Looks like tv_grab_nz-py can't handle the unicode characters and needs
>>>an update.
>>>
>>>hads
>>
>> I did the patches suggested here by Robin Gilks to my copy at some
>> point - I forget what problem they fixed, but it might have been this
>> one.  I know I needed the fixes.  Here is the diff:
>
>I think that's kinda the wrong way around? I take it you are adding
>the ISO-8859 bits, not taking them out. I was always taught "diff
>oldfile newfile".
>
>>
>> root at mypvr:/usr/local/bin# diff tv_grab_nz-0.2.6a-py tv_grab_nz-py
>> 23,25c23
>> < VERSION = '0.2.6a'
>> < # Modified by J S Worthington to work with Python 2.7 according to
>> mods by
>> < # Robin Gilks posted to the mythtvnz at lists.linuxnut.co.nz mailing
>> list.
>> ---
>>> VERSION = '0.2.6'
>> 29c27
>> <     'http://nzepg.org/freeview.xml.gz',
>> ---
>>>     'http://epg.org.nz/freeview.xml.gz',
>> 212,213c210
>> <     parser = ElementTree.XMLParser(encoding="ISO-8859-1")
>> <     doc = ElementTree.parse(StringIO(text), parser=parser).getroot()
>> ---
>>>     doc = ElementTree.parse(StringIO(text)).getroot()
>> 264,265c261
>> < parser = ElementTree.XMLParser(encoding="ISO-8859-1")
>> < doc = ElementTree.parse(StringIO(text), parser=parser).getroot()
>> ---
>>> doc = ElementTree.parse(StringIO(text)).getroot()

Oops!  I don't use diff often - I normally use my GUI tools.  Try
this:

root at mypvr:/usr/local/bin# diff tv_grab_nz-py tv_grab_nz-0.2.6a-py
23c23,25
< VERSION = '0.2.6'
---
> VERSION = '0.2.6a'
> # Modified by J S Worthington to work with Python 2.7 according to mods by
> # Robin Gilks posted to the mythtvnz at lists.linuxnut.co.nz mailing list.
27c29
<     'http://epg.org.nz/freeview.xml.gz',
---
>     'http://nzepg.org/freeview.xml.gz',
210c212,213
<     doc = ElementTree.parse(StringIO(text)).getroot()
---
>     parser = ElementTree.XMLParser(encoding="ISO-8859-1")
>     doc = ElementTree.parse(StringIO(text), parser=parser).getroot()
261c264,265
< doc = ElementTree.parse(StringIO(text)).getroot()
---
> parser = ElementTree.XMLParser(encoding="ISO-8859-1")
> doc = ElementTree.parse(StringIO(text), parser=parser).getroot()



More information about the mythtvnz mailing list