Unexpected behavior from xbmc.monitor() - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=26) +--- Thread: Unexpected behavior from xbmc.monitor() (/showthread.php?tid=317384) |
Unexpected behavior from xbmc.monitor() - Lunatixz - 2017-06-28 I've been encountering unexpected behavior from xbmc.monitor.waitForAbort, Everytime either a single video or the first playlist entry ends the loop breaks. I thought I was tracking a bug within xbmc.monitor(), but from what I can tell from the source this is a design feature? https://github.com/xbmc/xbmc/blob/72d0c23711f3805253a3771fd43e663652cd073a/xbmc/interfaces/legacy/Monitor.cpp Endtime thread from player is included as abortEvent? am I correctly reading the source? I wonder what would be the appropriate solution (workaround) for my situation? I'd like to have a loop running a function while a short video is playing... Would it be okay to use Code: while True: Example pseudo code below, thanks for any help. Code: SHORTCLIP = 20SECCLIP RE: Unexpected behavior from xbmc.monitor() - Roman_V_M - 2017-06-28 @Lunatixz Quote:I thought I was tracking a bug within xbmc.monitor(), but from what I can tell from the source this is a design feature? I'm not a C++ expert but I don't see anything player-related in the code. It looks like a homegrown solution similar to std::chrono, but, as I understand, most of Kodi codebase predates C++11, hence many homegrown solutions instead of modern std:: features. If the bug indeed occurs and reproducible, I guess you need to submit a bug report. RE: Unexpected behavior from xbmc.monitor() - Lunatixz - 2017-06-28 Yes that link doesn't but following the includes they lead to the XBMC.thread, system time and player both using a class called Endtime. I'm rusty with C, so I could be mistaken. I'll open a ticket since at least for me it's reproducible. Sent from my SM-G935T RE: Unexpected behavior from xbmc.monitor() - Lunatixz - 2017-06-28 https://trac.kodi.tv/ticket/17517#ticket |