Hi, folks! Is there any way to get failed task's s...
# prefect-community
м
Hi, folks! Is there any way to get failed task's state message (or failed task's name at least) inside flow-level state handler? I am trying to build a message for slack alert that contains information about particular reason of fail. But I want to try to declare state handler just once (e.g. on flow level).
1
k
The flow level won’t have access to task results so the answer here is no unless you query the GraphQL API. You can maybe create a downstream task with trigger any failed that takes in the output of the previous errored tasks and then send a message based from that
м
Yeah, got it. Thank you, will think about other ways