diff --git a/telegram_bot/bot_updates.py b/telegram_bot/bot_updates.py index e1fe445..e729e8a 100644 --- a/telegram_bot/bot_updates.py +++ b/telegram_bot/bot_updates.py @@ -40,7 +40,7 @@ def main_loop(): print(time.ctime()) # Debug - p1 = Process(target= update_crontab, args=(current_time_datetime, )) #Test threading instead of multiprocessing + p1 = Process(target= update_crontab, args=(current_time_datetime, )) p1.start() p3 = Process(target= update_based_on_crontab, args=(current_time_datetime, ) ) p3.daemon = True @@ -73,6 +73,7 @@ def update_crontab(pCurrent_Time): time_difference = datetime.datetime.now() - pCurrent_Time if float(str(time_difference).split(':')[0]) >=1: update_crontab(datetime.datetime.now()) + break def update_based_on_crontab(pCurrent_Time):