Hi everyone! We’re using a <flow-of-flows> for som...
# ask-community
f
Hi everyone! We’re using a flow-of-flows for some of our work and noticed that when a task inside one of the flows fails you only see a generic
some reference tasks failed
error message but you can’t see the stack trace the way you can when you run a ‘simple’ flow. Do you have any suggestions for how to implement error logging for flow-of-flows? I was thinking of using a state handler but those only know the ‘state’ of the flow as the name suggests and don’t have access to a stack trace. Curious to hear your thoughts! 🤔
a
Hi @Fina Silva-Santisteban, not sure if this will solve the logging issue, but you could try using create_flow_run + wait_for_flow_run instead of StartFlowRun. In this blog post, there is an example Flow and explanation of how it works: https://www.prefect.io/blog/prefect-0-15-0-a-new-flow-run-experience
k
Hey @Fina Silva-Santisteban, the error logs will appear in the subflow logs. You need to navigate to that subflow that was created and then view the logs there.
👌 1
upvote 1
a
@Fina Silva-Santisteban I was curious how does it work exactly and Kevin is right. Using both StartFlowRun and create_flow_run task, you should see in the logs a link to a FlowRun of a child flow, when the task is started. You can then drill down to the child Flow logs to find the stack trace
👌 1
f
@Kevin Kho @Anna Geller (old account) I can’t see seems to find links in the logs of the main flow but navigating to the subflows’s log through the ui worked for me! Thank you both!