[mythtv-users] 0.24 Python Bindings - Transcode Wrapper Script

Christopher Kerr mythtv at theseekerr.com
Sat Feb 19 01:24:25 UTC 2011


On Thu, Feb 17, 2011 at 3:13 AM, Raymond Wagner <raymond at wagnerrp.com> wrote:
> On 2/16/2011 10:54, Christopher Kerr wrote:
>> On Thu, Feb 17, 2011 at 2:51 AM, Christopher Kerr<mythtv at theseekerr.com>  wrote:
>>> On Thu, Feb 17, 2011 at 2:48 AM, Raymond Wagner<raymond at wagnerrp.com>  wrote:
>>>> On 2/16/2011 10:42, Christopher Kerr wrote:
>>>>> On Thu, Feb 17, 2011 at 2:35 AM, Raymond Wagner<raymond at wagnerrp.com>    wrote:
>>>>>> On 2/16/2011 10:26, Christopher Kerr wrote:
>>>>>>> NameError: global name 'findfile' is not defined
>>>>>> Fixed in the version on the wiki over a month ago.
>>>>> Raymond - I just grabbed a fresh copy from the wiki, and modified only
>>>>> the command and argument lines:
>>>>>
>>>>> Traceback (most recent call last):
>>>>>     File "./x264_inplace.py", line 96, in<module>
>>>>>       main()
>>>>>     File "./x264_inplace.py", line 88, in main
>>>>>       runjob(jobid=args[0])
>>>>>     File "./x264_inplace.py", line 17, in runjob
>>>>>       db = MythDB()
>>>>> NameError: global name 'MythDB' is not defined
>>>> The third line imports that class...
>>>>
>>>>>   from MythTV import Job, Recorded, System, MythDB, findfile, MythError
>>> OK, there's something really weird going on here....if I just visit
>>> http://www.mythtv.org/wiki?title=Transcode_wrapper_stub I get the old
>>> version.
>>>
>>> If I view the revisions and select the most recent, I get the version
>>> you're talking about.
>>>
>>> I'm still puzzled, but thanks!
>>>
>>> - Chris
>> OK, new issue!
>>
>> Traceback (most recent call last):
>>    File "./x264_inplace.py", line 96, in<module>
>>      main()
>>    File "./x264_inplace.py", line 88, in main
>>      runjob(jobid=args[0])
>>    File "./x264_inplace.py", line 36, in runjob
>>      task = System(path=transcoder, db=db)
>>    File "/usr/lib/pymodules/python2.6/MythTV/system.py", line 40, in __init__
>>      raise MythFileError('Defined grabber path does not exist.')
>> MythTV.exceptions.MythFileError: Defined grabber path does not exist.
>
> The script was originally written for 0.23, and 0.24 added a sanity
> check to ensure the selected file actually existed, but assumed the path
> was an absolute one.  I've backported a change from 0.25 that will also
> search the PATH for the file if the path does not begin with '/'.

Raymond,

I have applied your patch - the script now successfully calls the
transcoder, but fails at the next step:

kerr at MediaServer:/usr/share/doc/mythtv-backend/contrib/user_jobs$
/usr/share/doc/mythtv-backend/contrib/user_jobs/x264_inplace.py 1340
Traceback (most recent call last):
  File "/usr/share/doc/mythtv-backend/contrib/user_jobs/x264_inplace.py",
line 96, in <module>
    main()
  File "/usr/share/doc/mythtv-backend/contrib/user_jobs/x264_inplace.py",
line 88, in main
    runjob(jobid=args[0])
  File "/usr/share/doc/mythtv-backend/contrib/user_jobs/x264_inplace.py",
line 19, in runjob
    job = Job(jobid, db=db)
  File "/usr/lib/pymodules/python2.6/MythTV/database.py", line 284, in __init__
    DBData.__init__(self, data, db)
  File "/usr/lib/pymodules/python2.6/MythTV/database.py", line 153, in __init__
    self._pull()
  File "/usr/lib/pymodules/python2.6/MythTV/database.py", line 342, in _pull
    DBData._pull(self)
  File "/usr/lib/pymodules/python2.6/MythTV/database.py", line 169, in _pull
    raise MythError('DBData() could not read from database')
MythTV.exceptions.MythError: DBData() could not read from database


Any help would be appreciated,
- Chris


More information about the mythtv-users mailing list