rkarish commented on code in PR #29079:
URL: https://github.com/apache/airflow/pull/29079#discussion_r1083331570


##########
airflow/providers/common/sql/hooks/sql.py:
##########
@@ -197,8 +197,7 @@ def get_pandas_df(self, sql, parameters=None, **kwargs):
                 "'apache-airflow-providers-common-sql[pandas]'."
             )
 
-        with closing(self.get_conn()) as conn:
-            return psql.read_sql(sql, con=conn, params=parameters, **kwargs)
+        return psql.read_sql(sql, con=self.get_sqlalchemy_engine(), 
params=parameters, **kwargs)

Review Comment:
   Thank you for catching this @Taragolis, I should've looked deeper into the 
engine to see how the connection works, I made an assumption that it would be 
handled by sqlalchemy.



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