I’m looking to implement a script that calls a web API at regular intervals (e.g. every hour). I’m using Flask as my server.
Should I use the Cron framework, or is it better to use Python’s schedule
function to run the script?
asked May 23, 2018 at 13:59
1 Answer 1
Cron, otherwise you'll need something extra to make sure your python script is always running. Of course, this counts for cron too.
answered May 23, 2018 at 14:04
-
How would one initiate a scheduled task with Cron, other than manually starting the Cron schedule from the command line?charliesneath– charliesneath2018年05月23日 15:17:02 +00:00Commented May 23, 2018 at 15:17
-
That's the init systems job, good old sysvinit or bad new systemd.Gerard H. Pille– Gerard H. Pille2018年05月23日 20:40:32 +00:00Commented May 23, 2018 at 20:40
lang-py