ashb commented on a change in pull request #10956:
URL: https://github.com/apache/airflow/pull/10956#discussion_r501529477



##########
File path: airflow/jobs/scheduler_job.py
##########
@@ -1050,23 +754,17 @@ class SchedulerJob(BaseJob):  # pylint: 
disable=too-many-instance-attributes
 
     def __init__(
             self,
-            dag_id: Optional[str] = None,
-            dag_ids: Optional[List[str]] = None,
             subdir: str = settings.DAGS_FOLDER,
             num_runs: int = conf.getint('scheduler', 'num_runs'),
+            num_times_parse_dags: int = -1,

Review comment:
       It's not used in every test is the issue, so we don't want to always set 
it when unittest is enabled.

##########
File path: airflow/jobs/scheduler_job.py
##########
@@ -1050,23 +754,17 @@ class SchedulerJob(BaseJob):  # pylint: 
disable=too-many-instance-attributes
 
     def __init__(
             self,
-            dag_id: Optional[str] = None,
-            dag_ids: Optional[List[str]] = None,
             subdir: str = settings.DAGS_FOLDER,
             num_runs: int = conf.getint('scheduler', 'num_runs'),
+            num_times_parse_dags: int = -1,

Review comment:
       Will do

##########
File path: airflow/jobs/scheduler_job.py
##########
@@ -1050,23 +754,17 @@ class SchedulerJob(BaseJob):  # pylint: 
disable=too-many-instance-attributes
 
     def __init__(
             self,
-            dag_id: Optional[str] = None,
-            dag_ids: Optional[List[str]] = None,
             subdir: str = settings.DAGS_FOLDER,
             num_runs: int = conf.getint('scheduler', 'num_runs'),
+            num_times_parse_dags: int = -1,

Review comment:
       Added in d09c846d9 

##########
File path: airflow/models/dag.py
##########
@@ -1573,34 +1680,28 @@ def create_dagrun(self,
 
     @classmethod
     @provide_session
-    def bulk_sync_to_db(cls, dags: Collection["DAG"], sync_time=None, 
session=None):
+    def bulk_sync_to_db(cls, dags: Collection["DAG"], session=None):

Review comment:
       Done in 63ae0f5c4 - I settled on `bulk_write_to_db` (update could be 
taken to be UPDATE, but we will INSERT too)

##########
File path: tests/jobs/test_backfill_job.py
##########
@@ -160,10 +160,11 @@ def test_trigger_controller_dag(self):
         )
         job.run()
 
-        task_instances_list = dag_file_processor._process_task_instances(
-            target_dag,
-            dag_runs=DagRun.find(dag_id='example_trigger_target_dag')
-        )
+        task_instances_list = []

Review comment:
       Yes, working on this now.




----------------------------------------------------------------
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.

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


Reply via email to