For every Python X2go application you write, please make sure to
capture the KeyboardInterrupt and the
SystemExit exceptions and call this function if either of
the exceptions occurs.
Example:
import x2go
try:
my_x2goclient = x2go.X2goClient(...)
[... your code ...]
sys.exit(0)
except (KeyboardInterrupt, SystemExit):
x2go.x2go_cleanup()
- Parameters:
e (exception ) - if x2go_cleanup got called as you caught an
exception in your code this can be the Exception
that we will process at the end of the clean-up (or if clean-up
failed or was not appropriate)
threads (list ) - a list of threads to clean up
|