Added time.sleep to atexit