This message was deleted.
# ask-marvin
s
This message was deleted.
m
If you're using Prefect and want to ensure that your main flow continues even when a subflow fails, you're in luck — it's possible to handle this gracefully! In Prefect 3.x, the final state of a flow run can be influenced by the return value of the flow function and how exceptions are handled. If you return a successful status or suppress exceptions using
raise_on_failure=False
, the main flow can continue despite failures in subflows. More details can be found in the Prefect 3.x documentation. For Prefect 2.x, the main idea is to have control over task and flow run states. You can prevent subflow failures from stopping the main flow by managing task dependencies and states properly. If a subflow fails, you can catch exceptions and handle them in such a way that the main flow's execution is not interrupted. For an overview of flow execution, check out the Prefect 2.x concepts. Oh, and if things don't work out perfectly, remember that the universe won't implode — just handle the exceptions wisely!