Open ICEET opened 6 years ago
I added a periodic checker since the apschedular misses runtimes occasionally, this also occurs when the computer is put to sleep it will miss the trigger. Also value stop should be false in the file and changing it to true.
2018-04-30 22:54:54 - INFO - bot - APScheduler failed to schedule run, forcing run now 2018-04-30 22:54:54 - DEBUG - bot - Value stop modified 2018-04-30 22:54:54 - INFO - apscheduler.scheduler - Scheduler started 2018-04-30 22:54:54 - DEBUG - bot - Value run_now modified 2018-04-30 22:54:55 - DEBUG - bot - Value next_run_at modified to 2018-04-30 22:54:56.210498 2018-04-30 22:54:55 - INFO - apscheduler.scheduler - Added job "DuelLinkRunTime.in_main" to job store "default" 2018-04-30 22:54:55 - INFO - bot - Next run at 2018-04-30T22:54:56.210498 2018-04-30 22:54:56 - INFO - apscheduler.executors.default - Running job "DuelLinkRunTime.in_main (trigger: date[2018-04-30 22:54:56 PDT], next run at: 2018-04-30 22:54:56 PDT)" (scheduled at 2018-04-30 22:54:56.210498-07:00) 2018-04-30 22:54:56 - INFO - apscheduler.scheduler - Removed job cron_main_at_2018-04-30T22:54:56.210498 2018-04-30 22:54:56 - DEBUG - bot - Value last_run_at modified to 2018-04-30 22:54:56.213665 2018-04-30 22:54:56 - INFO - bot.provider.Nox - Checking for Start Screen 2018-04-30 22:54:56 - INFO - bot.provider.Nox - Waiting for DuelLinks Landing Page 2018-04-30 22:55:00 - DEBUG - bot.provider.Nox - LOOKING FOR BACK BUTTON, HIGH CORRERLATION 2018-04-30 22:55:01 - INFO - bot - starting auto play through 2018-04-30 22:55:01 - INFO - bot.provider.Nox - starting auto run through 2018-04-30 22:55:01 - DEBUG - bot.provider.Nox - Run through 1 ................................................ 2018-04-30 23:15:48 - DEBUG - bot.provider.Nox - Tapping at location (24,766) 2018-04-30 23:15:49 - DEBUG - bot.provider.Nox - LOOKING FOR BACK BUTTON, HIGH CORRERLATION 2018-04-30 23:15:52 - DEBUG - bot.provider.Nox - LOOKING FOR CLOSE BUTTON, HIGH CORRERLATION 2018-04-30 23:15:54 - DEBUG - bot.provider.Nox - LOOK FOR WORD 'OK', HIGH CORRERLATION 2018-04-30 23:15:58 - INFO - bot - completed auto play through 2018-04-30 23:15:58 - DEBUG - bot - Value next_run_at modified to 2018-04-30 23:20:58.274643 2018-04-30 23:15:58 - INFO - apscheduler.scheduler - Added job "DuelLinkRunTime.in_main.." to job store "default"
2018-04-30 23:15:58 - DEBUG - bot - Value stop modified
2018-04-30 23:15:58 - INFO - apscheduler.executors.default - Job "DuelLinkRunTime.in_main (trigger: date[2018-04-30 22:54:56 PDT], next run at: 2018-04-30 22:54:56 PDT)" executed successfully
2018-04-30 23:20:58 - INFO - apscheduler.executors.default - Running job "DuelLinkRunTime.in_main.. (trigger: date[2018-04-30 23:20:58 PDT], next run at: 2018-04-30 23:20:58 PDT)" (scheduled at 2018-04-30 23:20:58.274643-07:00)
2018-04-30 23:20:58 - INFO - apscheduler.scheduler - Removed job cron_main_at_2018-04-30T23:20:58.274643
2018-04-30 23:20:58 - INFO - apscheduler.executors.default - Job "DuelLinkRunTime.in_main.. (trigger: date[2018-04-30 23:20:58 PDT], next run at: 2018-04-30 23:20:58 PDT)" executed successfully
2018-04-30 23:27:52 - DEBUG - bot - Value stop modified
*I change self.next_run_at = datetime.datetime.now() + datetime.timedelta(minutes=5) for test.