##// END OF EJS Templates
make SIGUSR1 and SIGINFO trigger printing of info...
Paul Ivanov -
Show More
@@ -550,6 +550,10 b' class NotebookApp(BaseIPythonApplication):'
550 550 # but it will work
551 551 signal.signal(signal.SIGINT, self._handle_sigint)
552 552 signal.signal(signal.SIGTERM, self._signal_stop)
553 signal.signal(signal.SIGUSR1, self._signal_info)
554 if hasattr(signal, 'SIGINFO'):
555 # only on BSD-based systems
556 signal.signal(signal.SIGINFO, self._signal_info)
553 557
554 558 def _handle_sigint(self, sig, frame):
555 559 """SIGINT handler spawns confirmation dialog"""
@@ -600,6 +604,9 b' class NotebookApp(BaseIPythonApplication):'
600 604 self.log.critical("received signal %s, stopping", sig)
601 605 ioloop.IOLoop.instance().stop()
602 606
607 def _signal_info(self, sig, frame):
608 self.print_notebook_info()
609
603 610 @catch_config_error
604 611 def initialize(self, argv=None):
605 612 self.init_logging()
General Comments 0
You need to be logged in to leave comments. Login now