uranusjr commented on code in PR #31128:
URL: https://github.com/apache/airflow/pull/31128#discussion_r1188448224


##########
airflow/lineage/__init__.py:
##########
@@ -133,13 +134,16 @@ def wrapper(self, context, *args, **kwargs):
 
             # Remove auto and task_ids
             self.inlets = [i for i in self.inlets if not isinstance(i, str)]
-            _inlets = self.xcom_pull(context, task_ids=task_ids, 
dag_id=self.dag_id, key=PIPELINE_OUTLETS)
+            with create_session() as session:
+                _inlets = self.xcom_pull(
+                    context, task_ids=task_ids, dag_id=self.dag_id, 
key=PIPELINE_OUTLETS, session=session
+                )

Review Comment:
   Maybe some more explaination on where the new session is created, and why it 
will not be properly closed? Otherwise the first intuition for anyone reading 
this would be to try to fix that unclosed session.



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

Reply via email to