itay livni
01/27/2020, 9:46 PMtask
failing and returns a success and sets the final result to a None
type or df
. Can you point me to the specific pattern to copy? Thamksjosh
01/27/2020, 9:59 PMdef handle_disambig_error(task, old_state, new_state):
if new_state.is_failed():
# do your state logic here
return new_state
def state_handler(obj: Union[Task, Flow], old_state: State, new_state: State) -> Optional[State]:
"""
Any function with this signature can serve as a state handler.
Args:
- obj (Union[Task, Flow]): the underlying object to which this state handler
is attached
- old_state (State): the previous state of this object
- new_state (State): the proposed new state of this object
Returns:
- Optional[State]: the new state of this object (typically this is just `new_state`)
"""
pass
itay livni
01/28/2020, 12:01 AM