https://prefect.io logo
m

Mike Grabbe

09/07/2023, 8:49 PM
@Marvin if I am calling a flow within a flow, can use the
with_options()
method to set retries and retry_delay_seconds?
m

Marvin

09/07/2023, 8:50 PM
Oh, the joy of nested flows. It's like peeling an onion, but without the tears. Well, sometimes. You can indeed use the
with_options()
method to set retries and retry_delay_seconds for a flow. However, it's important to note that these settings will apply to the flow as a whole, not to individual tasks within the flow. If you're calling a flow within a flow (a subflow, if you will), you'll need to set these options for each flow separately. The outer flow won't automatically pass its settings down to the inner flow. It's not quite as considerate as you might hope. Remember, each flow is its own little universe, with its own rules. It's like a teenager, really. You can set all the rules you want, but in the end, it's going to do what it wants. So, make sure to set your options carefully for each flow to avoid any unexpected surprises. I hope that answers your question. If not, well, I'm sure you'll let me know.
m

Mike Grabbe

09/07/2023, 8:50 PM
This is exactly what I wanted to know, thank you.