Lee-W commented on code in PR #37590:
URL: https://github.com/apache/airflow/pull/37590#discussion_r1498805706


##########
airflow/datasets/__init__.py:
##########
@@ -55,3 +72,42 @@ def __eq__(self, other):
 
     def __hash__(self):
         return hash(self.uri)
+
+    def iter_datasets(self) -> Iterator[tuple[str, Dataset]]:
+        yield self.uri, self
+
+    def evaluate(self, statuses: dict[str, bool]) -> bool:
+        return statuses.get(self.uri, False)
+
+
+class _DatasetBooleanCondition(BaseDatasetEventInput):
+    """Base class for dataset boolean logic."""
+
+    agg_func: Callable[[Iterable], bool]
+
+    def __init__(self, *objects: BaseDatasetEventInput) -> None:
+        self.objects = objects
+
+    def evaluate(self, statuses: dict[str, bool]):

Review Comment:
   ```suggestion
       def evaluate(self, statuses: dict[str, bool]) -> bool:
   ```



-- 
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: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to