https://prefect.io logo
c

Christian Nuss

03/10/2022, 10:31 PM
Hey all! if a
state_handler
is being used on a
Flow
, and a
@task
has a
default_exception
and the
new_state
is
Failed
... is it possible to get that Exception for inspection in the state handler?
k

Kevin Kho

03/10/2022, 10:37 PM
No for flow level state handler, but you can get it for the task level state handler through the
new_state.result
. This is because task results are not kept throughout the Flow in Prefect Cloud since they can take a lot space
c

Christian Nuss

03/10/2022, 10:38 PM
wise choice! ok, i'll try a state_handler on the task