pierrejeambrun commented on code in PR #26872:
URL: https://github.com/apache/airflow/pull/26872#discussion_r1000925147


##########
airflow/providers/exasol/hooks/exasol.py:
##########
@@ -216,22 +216,20 @@ def get_autocommit(self, conn) -> bool:
 
         :param conn: Connection to get autocommit setting from.
         :return: connection autocommit setting.
-        :rtype: bool
         """
         autocommit = conn.attr.get('autocommit')
         if autocommit is None:
             autocommit = super().get_autocommit(conn)
         return autocommit
 
     @staticmethod
-    def _serialize_cell(cell, conn=None) -> object:
+    def _serialize_cell(cell, conn=None) -> object:  # type: ignore

Review Comment:
   This is because of an incompatible signature in regards to the base class 
(returns type are incompatible with `DbApiHook._serialize_cell`. 
   
   In my message up there (that was collapsed by github) I tried to enumerate 
these incompatibilities.
   
   I think a `# type: ignore[override]` is more appropriate and explicit. I 
just updated that thanks. (Updated for all of them: mysql, exasol and postgres).
   
   ~~Same for the `get_permission` and `create_permission` stated above~~. In 
fact there is only one subclass for `BaseSecurityManager`, so I was able to 
update the parent return type and get rid entirely of the incompatibilities 
between `BaseSecurityManager.get_permission` and 
`SecurityManager.get_permission` (same for `create_permission`)



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