INNER CODE UNIT · Python
delay
thevickypedia/Jarvis · jarvis/api/background_task/bot.py:111
delay = telegram_beat.failed_connections * EXPONENTIAL_BACKOFF_FACTOR
logger.info("Restarting in %d seconds.", delay)
await restart_loop(after=delay)
except Exception as error:
logger.critical("ATTENTION: %s", error)
communicator.notify(subject="JARVIS: Telegram", body=f"Telegram task failed due to {type(error).__name__}")
await terminate(reason=type(error).__name__)