Skip to content

Conversation

@tstrilka
Copy link
Contributor

Summary

Implements on_task_instance_skipped hook support in the OpenLineage provider listener to emit COMPLETE events when tasks are skipped via AirflowSkipException.

This is a follow-up to #59467 which added the on_task_instance_skipped hookspec to Airflow core.

Related: #59370

Changes

  • Added on_task_instance_skipped hookimpl to OpenLineageListener
  • Added _on_task_instance_skipped method to handle RuntimeTaskInstance (worker execution)
  • Extended _on_task_instance_manual_state_change to handle SKIPPED state (API/UI state changes)
  • Added 3 unit tests for the new functionality

Test plan

  • Unit tests added for:
    • RuntimeTaskInstance path (task raises AirflowSkipException)
    • Disabled operator check
    • TaskInstance path (manual state change via API)

@mobuchowski
Copy link
Contributor

@tstrilka code formatting is failing: https://github.com/apache/airflow/actions/runs/20921891743/job/60110209910?pr=60409

@tstrilka tstrilka force-pushed the openlineage-on-task-instance-skipped branch from 0e16d0e to 396324f Compare January 12, 2026 15:06
@mobuchowski mobuchowski merged commit f9e1e50 into apache:main Jan 12, 2026
89 checks passed
@tstrilka tstrilka deleted the openlineage-on-task-instance-skipped branch January 13, 2026 07:37
@tstrilka
Copy link
Contributor Author

Thanks for the review @mobuchowski! Appreciate the guidance on the original PR split as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants