Mohsin Ijaz
04/14/2026, 7:54 AMMarvin
04/14/2026, 7:55 AMMarvin
04/14/2026, 8:03 AM5 * * * * * → runs at the 5th second of every minute
- CLI:
prefect deployment schedule create <deployment-name> --cron "5 * * * * *" --timezone "UTC"
- Python:
from prefect import flow
from prefect.schedules import Cron
@flow
def my_flow():
...
my_flow.serve(
name="every-minute-at-5s",
schedule=Cron("5 * * * * *", timezone="UTC")
)
2) RRule (explicit seconds)
- Expression: FREQ=MINUTELY;BYSECOND=5
- CLI:
prefect deployment schedule create <deployment-name> --rrule "FREQ=MINUTELY;BYSECOND=5" --timezone "UTC"
- Python:
from prefect import flow
from prefect.schedules import RRule
@flow
def my_flow():
...
my_flow.serve(
name="every-minute-at-5s",
schedule=RRule("FREQ=MINUTELY;BYSECOND=5", timezone="UTC")
)
Notes:
- With cron in Prefect (via croniter), the 6-field format is “second minute hour day month day_of_week”, so 5 * * * * * means “at second 5 of every minute.”
- Add --timezone (or timezone= in Python) if you need a specific TZ.
Do you already have a deployment created, or would you like an example using flow.from_source(...).deploy(...) with schedules?Mohsin Ijaz
04/14/2026, 8:50 AMNate
04/14/2026, 5:15 PM* * * * * 5 or 5 * * * * * ? i thought it was the latter but then you said
I tried cron="* * * * * 5"