You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "uranusjr (via GitHub)" <gi...@apache.org> on 2023/05/08 08:52:30 UTC
[GitHub] [airflow] uranusjr commented on a diff in pull request #30706: Save scheduler execution time by checking if DAG has interval or timetable
uranusjr commented on code in PR #30706:
URL: https://github.com/apache/airflow/pull/30706#discussion_r1187198663
##########
airflow/jobs/scheduler_job_runner.py:
##########
@@ -1308,9 +1308,19 @@ def _create_dag_runs_dataset_triggered(
DatasetDagRunQueue.target_dag_id == dag_run.dag_id
).delete()
- def _should_update_dag_next_dagruns(self, dag, dag_model: DagModel, total_active_runs: int) -> bool:
+ def _should_update_dag_next_dagruns(
+ self, dag: DAG, dag_model: DagModel, session: Session, total_active_runs: int | None = None
+ ) -> bool:
Review Comment:
```suggestion
def _should_update_dag_next_dagruns(
self,
dag: DAG,
dag_model: DagModel,
total_active_runs: int | None = None,
*,
session: Session,
) -> bool:
```
Also adjust the callers to match the signature. Having `session` in the middle of the arguments is a bit messy to me.
--
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-unsubscribe@airflow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org