phanikumv commented on code in PR #42490:
URL: https://github.com/apache/airflow/pull/42490#discussion_r1776358035
##########
airflow/providers/common/sql/hooks/sql.py:
##########
@@ -210,6 +210,17 @@ def connection(self) -> Connection:
self._connection = self.get_connection(self.get_conn_id())
return self._connection
+ @connection.setter
+ def connection(self, value: Any) -> None:
+ # This dummpy setter is for backward compatibility and should not be
used.
Review Comment:
```suggestion
# This dummy setter is for backward compatibility and should not be
used.
```
##########
tests/providers/mysql/hooks/test_mysql.py:
##########
@@ -67,6 +67,21 @@ def test_get_conn(self, mock_connect):
assert kwargs["host"] == "host"
assert kwargs["db"] == "schema"
+ @mock.patch("MySQLdb.connect")
+ def test_dummpy_connection_setter(self, mock_connect):
Review Comment:
```suggestion
def test_dummy_connection_setter(self, mock_connect):
```
--
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]