Skip to content

Instantly share code, notes, and snippets.

@anna-anisienia
Created August 27, 2020 21:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anna-anisienia/72a610578b2936ba4248349d395b2cb9 to your computer and use it in GitHub Desktop.
Save anna-anisienia/72a610578b2936ba4248349d395b2cb9 to your computer and use it in GitHub Desktop.
from prefect.schedules import Schedule
from prefect.schedules.clocks import CronClock
import pendulum
schedule = Schedule(clocks=[CronClock("0 2 * * *",
start_date=pendulum.datetime(2020, 8, 28,
tz="Europe/Berlin")
)])
schedule.next(3) # to see next 3 schedules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment