add on_success/on_failure to task