Can't get service addon to stop from XBMC - Printable Version
+- XBMC Community Forum (http://forum.xbmc.org)
+-- Forum: Development (/forumdisplay.php?fid=32)
+--- Forum: Python Add-on Development (/forumdisplay.php?fid=26)
+--- Thread: Can't get service addon to stop from XBMC (/showthread.php?tid=123492)
Can't get service addon to stop from XBMC - Gujs - 2012-02-20 23:20
I am trying to extend service addons in openelec system. I am trying to implement possibility to stop service addon when it is disabled by user. This way we would also gain a restart of service addon when it is upgraded. Right now our user have to reboot if they upgrade service addons which are made by openelec maintainers.
I thought I can do this by using xbmc.abortRequested in the default.py but I found out that xbmc closes python to fast to process all the code after.
Here is the code I use:
I added while counter just for checking why thing are not working. This code should shutdown tvheadend process when I disable tvheadend service addon in addon information. But instead of that it even doesn't get to that part of code, mostly python thread is already closed when counter counts to 5.
Here is the part of log when I try to disable the addon:
I would like to know if I am doing something wrong or I just found an xbmc bug on service addons. I would really appreciate some help from experts on this filed.
PS: Sorry for posting on the wrong forum section. Please move to Python Script and Plugin Addon Development. Thank You.
- giftie - 2012-02-21 02:16
I think this has been fixed in the master -> https://github.com/xbmc/xbmc/commit/e6bf089bbf486c9879d3abc5ce31a99b67558ea7
- Gujs - 2012-02-21 12:01
Thanks. I hope it will be back-ported to Eden branch :-)