[mythtv-users] Mirobridge failing to update mythtv db entries

R.D. Vaughan rdvandroid at gmail.com
Fri Jun 13 17:43:14 UTC 2014


Daniel,
Here is something to try. As your DB knowledgeable you can find a "Record" record from another Miro channel and copy that record but change the title and inetref number to match the Miro channel for the video that was downloaded.  I think it was Tekzilla.  The title must be an exact match to what you call it on Miro. Look up that channel title on thetvdb.org web site to get the Internet number (see end of url) . Then add the new record, this will avoid MiroBridge adding the record itself. 

Obviously this is not a solution but may get you going.  To me the last test you did with the cut and paste code showed that this is not a MiroBridge issue. 

I've run out of ideas. 

Doug 

On June 11, 2014 10:57:35 PM EDT, Daniel Frey <dmfrey at gmail.com> wrote:
>On Jun 11, 2014 9:40 PM, "rdvAndroid at gmail.com" <rdvandroid at gmail.com>
>wrote:
>>
>> Daniel,
>>
>> Cut and paste the following lines in a terminal session on the BE
>thatyou
>run Mirobridge:
>> ----------------------------- Cut code starting on next line
>> python
>> from MythTV import Record
>> makeRecordRule = {'chanid': "9999", 'description': u'Mirobridge
>Record
>rule used to acquire ttvdb.com artwork',
>>                                'autometadata': 1, 'season': 1,
>'episode':
>1, 'category': u'Miro', 'station': u'Miro'  }
>> makeRecordRule['title'] = "Tekzilla"
>> makeRecordRule['inetref'] = "999999"
>> record = Record().create(makeRecordRule)
>> print record
>> record.delete()
>> exit(0)
>> ---------------------------- Stop cutting code prior to this line
>>
>> My results with an environment that has a working MiroBridge looks
>like
>this:
>> doug at ubuntuQuad:~$ python
>> Python 2.7.3 (default, Feb 27 2014, 19:37:34)
>> [GCC 4.7.2] on linux2
>> Type "help", "copyright", "credits" or "license" for more
>information.
>> >>> from MythTV import Record
>> >>> makeRecordRule = {'chanid': "9999", 'description': u'Mirobridge
>Record rule used to acquire ttvdb.com artwork',
>> ...                                'autometadata': 1, 'season': 1,
>'episode': 1, 'category': u'Miro', 'station': u'Miro'  }
>> >>> makeRecordRule['title'] = "Tekzilla"
>> >>> makeRecordRule['inetref'] = "999999"
>> >>> record = Record().create(makeRecordRule)
>> >>> print record
>> <Record Rule 'Tekzilla', Type 11 at 0x10e42c0>
>> >>> record.delete()
>> >>> exit(0)
>> doug at ubuntuQuad:~$
>>
>> If your environment aborts then the issue is in your environement.
>The
>code above is the standard way to create a "Record" record using the
>MythTV
>python bindings. If the record is created then it is immediately
>deleted so
>you will not need to clean up your database after running the test. You
>can
>run this test as many times as you like as long as you include the
>"record.delete()" statement.
>>
>> Please paste back the results of your test.
>>
>> Thanks
>>
>>
>> Doug
>> _______________________________________________
>> mythtv-users mailing list
>> mythtv-users at mythtv.org
>> http://www.mythtv.org/mailman/listinfo/mythtv-users
>> http://wiki.mythtv.org/Mailing_List_etiquette
>> MythTV Forums: https://forum.mythtv.org
>
>Doug,
>Thanks for your help.  Here is the output I received. It did error out.
>
>dmfrey at mythcenter:~$ python
>Python 2.7.3 (default, Feb 27 2014, 19:58:35)
>[GCC 4.6.3] on linux2
>Type "help", "copyright", "credits" or "license" for more information.
>>>> from MythTV import Record
>>>> makeRecordRule = {'chanid': "9999", 'description': u'Mirobridge
>Record
>rule used to acquire ttvdb.com artwork',
>...                                'autometadata': 1, 'season': 1,
>'episode': 1, 'category': u'Miro', 'station': u'Miro'  }
>>>> makeRecordRule['title'] = "Tekzilla"
>>>> makeRecordRule['inetref'] = "999999"
>>>> record = Record().create(makeRecordRule)
>Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
>File "/usr/lib/python2.7/dist-packages/MythTV/dataheap.py", line 161,
>in
>__init__
>    DBDataWrite.__init__(self, data, db)
>File "/usr/lib/python2.7/dist-packages/MythTV/database.py", line 317,
>in
>__init__
>    DBData.__init__(self, data, db)
>File "/usr/lib/python2.7/dist-packages/MythTV/database.py", line 169,
>in
>__init__
>    self._setDefs()
>File "/usr/lib/python2.7/dist-packages/MythTV/database.py", line 305,
>in
>_setDefs
>    DBData._setDefs(self)
>File "/usr/lib/python2.7/dist-packages/MythTV/database.py", line 160,
>in
>_setDefs
>    self.__class__._setClassDefs(self._db)
>File "/usr/lib/python2.7/dist-packages/MythTV/dataheap.py", line 118,
>in
>_setClassDefs
>    defaults = cls._template('Default', db=db)
>File "/usr/lib/python2.7/dist-packages/MythTV/dataheap.py", line 128,
>in
>_template
>    tmp = cls._fromQuery("WHERE title=?", (name + " (Template)",))\
>StopIteration
>>>> print record
>Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
>NameError: name 'record' is not defined
>>>> record.delete()
>Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
>NameError: name 'record' is not defined
>>>> exit(0)
>
>Dan
>
>
>------------------------------------------------------------------------
>
>_______________________________________________
>mythtv-users mailing list
>mythtv-users at mythtv.org
>http://www.mythtv.org/mailman/listinfo/mythtv-users
>http://wiki.mythtv.org/Mailing_List_etiquette
>MythTV Forums: https://forum.mythtv.org

-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mythtv.org/pipermail/mythtv-users/attachments/20140613/a5102571/attachment.html>


More information about the mythtv-users mailing list