libgs.utils.safe_sleep

libgs.utils.safe_sleep(t)[source]

Sleep for a specified number of seconds.

safe_sleep uses a subset of the wait_loop() capabilities to implement an anologe to the time.sleep() function. The advantage is that it will raise an exception if the global abort event gets set, and as such is safe to use in thread loops that need to exit on adfa-gs exit.