hey can i enforce a complete flow retry when task ...
# ask-community
d
hey can i enforce a complete flow retry when task fails instead of only retrying from the task that failed?
k
Hey @Dotan Asselmann, ultimately you have to create a new flow run because the tasks of the current flow run have already succeeded by that point. You can do this by using a state handler attached to the flow that kicks off a new run is the state is Failed. I think the easiest way to do this is to use the
StartFlowRun
inside the state handler and call the run method explicitly like
StartFlowRun(…).run()
. Then you can pass the scheduled_start_time to schedule it. I don’t know if this is your intention but you might run into an infinite loop here.
d
gotit. thanks!
👍 1