Fredrik Hoem Grelland
12/05/2025, 12:19 PMMarvin
12/05/2025, 12:20 PMMarvin
12/05/2025, 12:21 PMretry_jitter_factor for flows. Flows support retries and a fixed `retry_delay_seconds`; jitter is only available on tasks.
- Flow options:
@flow(retries=3, retry_delay_seconds=60)
def my_flow():
...
Docs: Flow decorator
- Task options (with jitter):
@task(
retries=5,
retry_delay_seconds=[5, 10, 20, 40, 80],
retry_jitter_factor=0.2,
)
def my_task(...):
...
Docs: Task decorator
Common workarounds if you need flow-level jitter:
- Put the retry/jitter on the critical task(s) instead of the whole flow.
- Build a “supervisory” parent flow that calls your real flow as a subflow and implements its own sleep-with-jitter between attempts. This won’t show as native flow retries in the UI (you’ll see multiple subflow runs instead), but it lets you control jitter timing.