Lee-W commented on code in PR #76002:
URL: https://github.com/apache/airflow/pull/76002#discussion_r4420563388
##########
airflow-core/src/airflow/jobs/scheduler_job_runner.py:
##########
@@ -314,6 +318,18 @@ def _create_scheduler_dag_bag() -> CachedDBDagBag:
)
+def _scheduled_asset_event(dag_id: str) -> ColumnElement[bool]:
Review Comment:
```suggestion
def _build_scheduled_asset_event_clause(dag_id: str) -> ColumnElement[bool]:
```
nit
##########
airflow-core/src/airflow/models/asset.py:
##########
@@ -811,6 +812,44 @@ def __repr__(self):
)
+def consumed_by_dag(
Review Comment:
```suggestion
def is_consumed_by_dag(
```
nit
##########
airflow-core/src/airflow/models/asset.py:
##########
@@ -811,6 +812,44 @@ def __repr__(self):
)
+def consumed_by_dag(
+ dag_id: str | SQLColumnExpression[str], event_id: SQLColumnExpression[int]
+) -> ColumnElement[bool]:
+ """Check whether the asset event *event_id* has been consumed by a run of
the Dag *dag_id*."""
+ from airflow.models.dagrun import DagRun
Review Comment:
should we import from top level instead?
--
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]