Say a `Flow` run fails. Is there a recommended way...
# prefect-community
b
Say a
Flow
run fails. Is there a recommended way to store the state of the failed run so that I could load it up, raise the exception stored in the failed task’s result, and step into a debugger?
👀 1
l
Hi @Ben Fogelson, if you’ve got the state object in-memory already from running the flow interactively, these docs will help: https://docs.prefect.io/core/advanced_tutorials/local-debugging.html#re-raising-execeptions-post-hoc If you are using server or cloud so don’t have the state object handy, there’s not really a great way to hydrate it completely, but you might consider preventatively persisting the state of a flow as a cloudpickle via a flow-level state handler, which you could deserialize for debugging purposes using those same local debugging tips from those docs!