dabla commented on code in PR #40751:
URL: https://github.com/apache/airflow/pull/40751#discussion_r1696381417
##########
airflow/providers/common/sql/hooks/sql.py:
##########
@@ -202,9 +204,28 @@ def placeholder(self):
)
return self._placeholder
+ @property
+ def connection(self) -> Connection:
+ if self._connection is None:
+ self._connection = self.get_connection(self.get_conn_id())
+ return deepcopy(self._connection)
Review Comment:
No idea either, but I just moved that code from the OdbcHook into the
DbApiHook, no idea why they did a deepcopy of the connection in the OdbcHook,
will be a reason for it...
--
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]