diff --git a/cosmos/airflow/graph.py b/cosmos/airflow/graph.py index c4e48ae19..d45dd095b 100644 --- a/cosmos/airflow/graph.py +++ b/cosmos/airflow/graph.py @@ -174,7 +174,11 @@ def build_airflow_graph( use_name_as_task_id_prefix=test_behavior != TestBehavior.AFTER_EACH, ) if task_meta and node.resource_type != DbtResourceType.TEST: - if node.resource_type == DbtResourceType.MODEL and node.has_test == True and test_behavior == TestBehavior.AFTER_EACH: + if ( + node.resource_type == DbtResourceType.MODEL + and node.has_test is True + and test_behavior == TestBehavior.AFTER_EACH + ): with TaskGroup(dag=dag, group_id=node.name, parent_group=task_group) as model_task_group: task = create_airflow_task(task_meta, dag, task_group=model_task_group) test_meta = create_test_task_metadata( diff --git a/cosmos/dbt/graph.py b/cosmos/dbt/graph.py index 2f8008a5a..702e9bd49 100644 --- a/cosmos/dbt/graph.py +++ b/cosmos/dbt/graph.py @@ -352,7 +352,7 @@ def load_from_dbt_manifest(self) -> None: logger.info("Total nodes: %i", len(self.nodes)) logger.info("Total filtered nodes: %i", len(self.nodes)) - + def update_node_dependency(self) -> None: """ This will update the node if has `dbt` test