code: def exit_on_keyboard_interrupt(f):
      
      @wraps(f)
      def wrapper(*args, **kwargs):
          raise_exception = kwargs.pop('raise_exception', False)
          try:
              return f(*args, **kwargs)
          except KeyboardInterrupt:
              if not raise_exception:
                  sys.exit()
              raise KeyboardInterrupt
      return wrapper
docs: Decorator that allows user to exit script by sending a keyboard interrupt
      (ctrl + c) without raising an exception.