WIP Clock Screensaver [Alpha Released]
#16
Screensaver updated
Added clock color and an background image


Under windows this happens
Code:
14:09:27 T:4964  NOTICE: 1 Python Screensaver Started
14:09:27 T:4964  NOTICE: 2 Screensaver: onInit
14:09:27 T:4964  NOTICE: Time color: 0
14:09:29 T:4964  NOTICE: 3 ExitMonitor: sending exit_callback
14:09:29 T:4964  NOTICE: 4 Screensaver: Exit requested
14:09:39 T:6736   ERROR: XBPyThread::stop - script C:\Users\brantje\AppData\Roaming\XBMC\addons\screensaver.clock\default.py didn't stop in 5 seconds - let's kill it
14:09:39 T:4964   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.SystemExit'>
                                            Error Contents: <NULL>
                                            Traceback (most recent call last):
                                              File "C:\Users\brantje\AppData\Roaming\XBMC\addons\screensaver.clock\default.py", line 75, in onInit
                                                now  = datetime.now()
                                            SystemExit
                                            -->End of Python script error report<--
14:09:39 T:4964  NOTICE: 5 Python Screensaver Exited
14:09:39 T:4964 WARNING: The python script "C:\Users\brantje\AppData\Roaming\XBMC\addons\screensaver.clock\default.py" has left several classes in memory that we couldn't clean up. The classes include: WindowXMLDialog,Monitor

Under xbian:
Code:
13:32:03 T:2874143808  NOTICE: 1 Python Screensaver Started
13:32:03 T:2874143808  NOTICE: 2 Screensaver: onInit
13:32:05 T:2874143808  NOTICE: Time color: 0
14:10:10 T:2874143808  NOTICE: 3 ExitMonitor: sending exit_callback
14:10:10 T:2874143808  NOTICE: 4 Screensaver: Exit requested
14:10:10 T:2883789888  NOTICE: Thread Jobworker start, auto delete: true
14:10:11 T:2924991552  NOTICE: screensaver Deactivated
14:10:20 T:3041865728   ERROR: XBPyThread::stop - script /home/xbian/.xbmc/addons/screensaver.clock/default.py didn't stop in 5 seconds - let's kill it
14:10:20 T:2874143808   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.SystemExit'>
                                            Error Contents: <NULL>
                                            Traceback (most recent call last):
                                              File "/home/xbian/.xbmc/addons/screensaver.clock/default.py", line 75, in onInit
                                                hour = now.hour
                                            SystemExit
                                            -->End of Python script error report<--
14:10:20 T:2874143808  NOTICE: 5 Python Screensaver Exited
14:10:20 T:2874143808 WARNING: The python script "/home/xbian/.xbmc/addons/screensaver.clock/default.py" has left several classes in memory that we couldn't clean up. The classes include: Monitor,WindowXMLDialog

How do i correctly stop the script?
Reply
#17
Maybe change your while loopHuh something like -

while not xbmc.abortRequested
Reply
#18
(2013-06-26, 14:36)divingmule Wrote: Maybe change your while loopHuh something like -

while not xbmc.abortRequested

No, don't use xbmc.abortRequested. You already have a (non polling) exit_callback, you need to set your own abort_requested flag in the exit_callback method. Then (if you have a loop or any modal or blocking code) you need to check for it and return the current function and call the window.close() method.

I created a fork of your add-on to demonstrate a proper (non xbmc.abortRequested) exit:
https://github.com/dersphere/screensaver......patch-1
My GitHub. My Add-ons:
Image
Reply
#19
Very cool app, first time on XBMC forum. Didn't expect this much activity glad to c new stuff
Reply
#20
(2013-06-26, 14:41)sphere Wrote:
(2013-06-26, 14:36)divingmule Wrote: Maybe change your while loopHuh something like -

while not xbmc.abortRequested

No, don't use xbmc.abortRequested. You already have a (non polling) exit_callback, you need to set your own abort_requested flag in the exit_callback method. Then (if you have a loop or any modal or blocking code) you need to check for it and return the current function and call the window.close() method.

I created a fork of your add-on to demonstrate a proper (non xbmc.abortRequested) exit:
https://github.com/dersphere/screensaver......patch-1

Thanks, for the example. New code is on github.
Fixes crash on windows and a couple of other bugs.
Reply
#21
Github updated, added a option for background slideshow.
and 12/24 hour + AM/PM
Reply
#22
Hi brantje, I've just found your screensaver.
Looks good!
Have you tried adding anything to it recently?
Digital Clock Screensaver with a lot of options - check it out!
Reply

Logout Mark Read Team Forum Stats Members Help
Clock Screensaver [Alpha Released]0