From 5571ae24d2969d81f0a916a422efae15d6822394 Mon Sep 17 00:00:00 2001 From: michivonah Date: Mon, 2 Oct 2023 22:15:39 +0200 Subject: [PATCH] create main loop --- main.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index bc7ac41..bcc5aa9 100644 --- a/main.py +++ b/main.py @@ -2,6 +2,7 @@ import requests import os from dotenv import load_dotenv from discord_webhook import DiscordWebhook +import time load_dotenv() @@ -33,5 +34,8 @@ def checkTimes(subscribedAttractions, alertlimit): # Main if __name__ == '__main__': - checkTimes(subscribedAttractions, waitingtimeAlert) + while True: + checkTimes(subscribedAttractions, waitingtimeAlert) + print(f"Checked for updates at {time.strftime('%H:%M:%S', time.localtime())}") + time.sleep(30)