Pārlūkot izejas kodu

try the schedule library (container problem)

marton levente 11 mēneši atpakaļ
vecāks
revīzija
da891774dd
1 mainītis faili ar 15 papildinājumiem un 0 dzēšanām
  1. 15 0
      scheduled.py

+ 15 - 0
scheduled.py

@@ -0,0 +1,15 @@
+'''Created 3 Oct 2023 Levi'''
+import time
+import schedule
+
+import mail_alert
+
+schedule.every(5).seconds.do(mail_alert.mail_alert)
+schedule.every(5).seconds.do(mail_alert.mail_alert2)
+schedule.every(5).seconds.do(mail_alert.mail_alert3)
+
+
+if __name__ == '__main__':
+    while True:
+        schedule.run_pending()
+        time.sleep(1)