Onionr/src/utils/bettersleep.py

11 lines
177 B
Python
Raw Normal View History

from time import sleep
def better_sleep(wait: int):
"""Sleep catching ctrl c for wait seconds."""
try:
sleep(wait)
except KeyboardInterrupt:
pass