Why does this script freeze 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: Why does this script freeze XBMC (/showthread.php?tid=74159)
Why does this script freeze XBMC - dennis - 2010-05-19 00:56
I've been running this script for several years on the XBOX (it slightly modified, but the unmodified hangs too).
I have now an Asrock ION 330 and I've put the script into autoexec.py and now it freezes when I try to shut down XBMC.
Can I change the script so it won't freeze?
- dennis - 2010-05-21 15:58
- elupus - 2010-05-21 19:31
Hmm, not sure.. We really should have some function call called when we want python to shut down.. your script won't stop unless the socket errors out.
I don't think we actually do any type of shutdown call currently.
- elupus - 2010-05-22 00:06
Okey, now there is a bool called "xbmc.abortRequested" in svn which you can use in your while loop to check if we want the script to abort.
Your script still needs some adjustment so that you add some select call on your socket with timeout so that you recheck that bool from time to time.
- Nuka1195 - 2010-05-22 01:52
elupus since you changes, here is a log of xbmc freezing at start.
i have the weather script and recently added script running at startup.
if i rename the recentlyadded script it starts normal. so maybe a conflict when two or more scripts run at the same time or the fact the recentlyadded script is accessing the database?
i did have to revert jmarshalls change to run scripts under cpluff as i couldn't get scripts to run with cpluff. the addon.xml format is wrong i'm sure.
but i did this before your change so i don't think it is a problem?
edit: it seems it's just the recentlyadded script. i deleted the entry for weather script and it still freezes.
- elupus - 2010-05-22 02:02
Nuka1195, okey.. i wonder how that happened.. how is it run on startup?
That scripts seems to be crashing for me.
- Nuka1195 - 2010-05-22 02:14
sorry for thread jacking, but maybe it helps with the op problem.
if your using the default skin. it is run by:
mine is run basically the same, but from startup.xml. maybe that's the issue. it starts too early in the process?
you need to update the script from what jezz has in his scripts folder. i think. you should have it in xbmc repo somewhere i can upload the script i'm using if you need.
- Nuka1195 - 2010-05-22 02:17
here just in case. http://xbmc-addons.googlecode.com/svn/packages/RecentlyAdded.zip
- elupus - 2010-05-22 02:21
think my issue is with my messed up library.. can you repro the issue with stock skin?
- Nuka1195 - 2010-05-22 02:27
it runs fine from home.xml. so must be running from startup.xml is too early now.
edit: maybe that sleep you removed allowed it to work before?