Hi everyone, We have a failure callback on our fl...
# prefect-community
m
Hi everyone, We have a failure callback on our flows that tries to report all of the exceptions that occurred in each task. We previously tried to access the
state.result
from the flow which works locally but not in the cloud explained in this answer https://prefect-community.slack.com/archives/CL09KU1K7/p1653606914417649. Is there a good way to collect exceptions from each task and report them in a state handler when the flow fails? We have have alerts on flow failures and we want to report the exceptions in the alert
k
You have 2 options: 1. query for the task run states in a Flow level state handler right before completion 2. have a last task that everything feeds to for reporting purposes
m
If we query for the task run states will they have the results with the exceptions in memory? We don’t have persistent results set up yet
k
There should be a message attached to the state
m
Thanks so much!
👍 1