dstandish commented on code in PR #31808:
URL: https://github.com/apache/airflow/pull/31808#discussion_r1227563267
##########
airflow/triggers/base.py:
##########
@@ -119,3 +119,34 @@ def __eq__(self, other):
if isinstance(other, TriggerEvent):
return other.payload == self.payload
return False
+
+
+class BaseTaskEndEvent(TriggerEvent):
+ """Base event class to end the task without resuming on worker."""
+
+ task_instance_state: TaskInstanceState
+
+ def __init__(self, *, xcom_return: Any | None = None, other_xcom:
dict[str, Any] | None = None, **kwargs):
+ if "payload" in kwargs:
+ raise ValueError("Param 'payload' not supported for this class.")
Review Comment:
if we do not check, user might pass `payload` and it would be silently
ignored
--
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]