catch KeyboardInterrupt