Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rename events & run in hook functions #408

Merged
merged 1 commit into from
May 14, 2024

Conversation

essweine
Copy link
Contributor

This PR adds an optional callback when a task transitions to an error state and aligns the existing callbacks with task states. It also moves execution into the hook functions where applicable. entereted_event was renamed to update_event, finished_event was changed to run_event and reached_event was removed`. The current set of callbacks are

  • update_event (emitted in _update_hook)
  • ready_event (emitted in _on_ready_hook)
  • completed_event (emitted in _on_complete_hook on successful completion)
  • error_event (emitted in _on_error_hook on unsuccessful completion)
  • run_event (emitted in _run_hook whenever a task is run regardless of result)
  • cancelled_event (called in _on_cancel)

@essweine essweine merged commit ac2d8f3 into main May 14, 2024
5 checks passed
@essweine essweine deleted the feature/align-callbacks-with-state-transitions branch May 14, 2024 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants