IndiTheo commented on code in PR #76110:
URL: https://github.com/apache/airflow/pull/76110#discussion_r4436818005


##########
airflow-core/newsfragments/76110.feature.rst:
##########
@@ -0,0 +1 @@
+The callback context now includes a ``callback`` key whose ``source`` field 
tells you whether the callback ran at the Dag level or the task level.

Review Comment:
   Fixed



##########
task-sdk/src/airflow/sdk/definitions/context.py:
##########
@@ -18,10 +18,35 @@
 from __future__ import annotations
 
 import copy
+import enum
 import os
 from collections.abc import MutableMapping
 from typing import TYPE_CHECKING, Any, NamedTuple, NotRequired, TypedDict, cast
 
+
+class CallbackSource(str, enum.Enum):
+    """Whether a callback was triggered at the DAG level or the task level."""

Review Comment:
   Fixed



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to