labscript-suite / runmanager

𝗿𝘂𝗻𝗺𝗮𝗻𝗮𝗴𝗲𝗿 is an intuitive graphical interface for controlling 𝘭𝘢𝘣𝘴𝘤𝘳𝘪𝘱𝘵 𝘴𝘶𝘪𝘵𝘦 experiments. Includes multi-dimensional parameter scans and a remote programming interface for automation.
http://labscriptsuite.org
Other
3 stars 45 forks source link

Graceful shutdown on ctrl-c #84

Closed chrisjbillington closed 4 years ago

chrisjbillington commented 4 years ago

The existing signal handler killed Python unceremoniously, not allowing it to run atexit functions or any other kind of cleanup (not releasing zlock locks or anything). Have a ctrl-C do qapplication.exit() instead so that shutdown is graceful.

This is the tried-and-true method used in e.g lyse.