Quantcast
Channel: User Bijan - Stack Overflow
Viewing all articles
Browse latest Browse all 99

APScheduler Runs Too Early with Jitter

$
0
0

I have a script that runs a function WOL() on Friday's at 8:05AM with a Jitter of 15 minutes.

My code is:

def WOL():    response.post("https://example.com/WOL.php")PC = sched.add_job(WOL, 'cron', hour=8, minute=5, jitter=900, day_of_week='fri')sched.start()print(PC.next_run_time) # Returns 2024-02-02 07:56:38.273177-08:00

According to the man-page for apscheduler.triggers.cron, jitter will "delay the job execution by jitter seconds at most".

If I set a start time of 8:05AM with jitter of 15min, why would it be trigerred 10minutes before it is supposed to run?


Viewing all articles
Browse latest Browse all 99

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>