[mythtv-users] writeStringList error no data written on writeBlock (Python bindings?)

Raymond Wagner raymond at wagnerrp.com
Sun Sep 8 22:44:36 UTC 2013


On 9/8/2013 6:05 PM, Roger Siddons wrote:
> db = MythTV.MythDB()
> be = MythTV.BECache(None, False, db)
>
> # send advert skiplist to MythPlayers
> tuplelist = [(str(x) + ':' + str(rec.markup.MARK_COMM_START), str(y) +
> ':' + str(rec.markup.MARK_COMM_END)) for x, y in rec.markup.getskiplist()]
> mesg = 'COMMFLAG_UPDATE ' + progId + ' ' + ','.join([x for tuple in
> tuplelist for x in tuple])
> result = be.backendCommand("MESSAGE[]:[]" + mesg)
>
> Not great code but it was my first attempt at Python and I couldn't find
> any examples to copy...

I've honestly done very little mapping of the event messages, so your 
guess is as good as mine about how this one is supposed to function.

> I did notice http://www.gossamer-threads.com/lists/mythtv/dev/548233 but
> it's probably the way I'm using the bindings.

This had to do with inserting skip lists directly into the database, so 
it would not apply to what you are doing.


More information about the mythtv-users mailing list