@@ -94,7 +94,7 @@ def is_closed(self, conn: Connection) -> bool:
9494 if self .can_execute_query (conn ):
9595 socket_timeout = WrapperProperties .SOCKET_TIMEOUT_SEC .get_float (self ._props )
9696 timeout_sec = socket_timeout if socket_timeout > 0 else MySQLDriverDialect .IS_CLOSED_TIMEOUT_SEC
97- is_connected_with_timeout = timeout (MySQLDriverDialect ._executor , timeout_sec )(conn .is_connected )
97+ is_connected_with_timeout = timeout (MySQLDriverDialect ._executor , timeout_sec )(conn .is_connected ) # type: ignore
9898
9999 try :
100100 return not is_connected_with_timeout ()
@@ -106,14 +106,14 @@ def is_closed(self, conn: Connection) -> bool:
106106
107107 def get_autocommit (self , conn : Connection ) -> bool :
108108 if MySQLDriverDialect ._is_mysql_connection (conn ):
109- return conn .autocommit
109+ return conn .autocommit # type: ignore
110110
111111 raise UnsupportedOperationError (
112112 Messages .get_formatted ("DriverDialect.UnsupportedOperationError" , self ._driver_name , "autocommit" ))
113113
114114 def set_autocommit (self , conn : Connection , autocommit : bool ):
115115 if MySQLDriverDialect ._is_mysql_connection (conn ):
116- conn .autocommit = autocommit
116+ conn .autocommit = autocommit # type: ignore
117117 return
118118
119119 raise UnsupportedOperationError (
@@ -132,13 +132,13 @@ def abort_connection(self, conn: Connection):
132132
133133 def can_execute_query (self , conn : Connection ) -> bool :
134134 if MySQLDriverDialect ._is_mysql_connection (conn ):
135- if conn .unread_result :
136- return conn .can_consume_results
135+ if conn .unread_result : # type: ignore
136+ return conn .can_consume_results # type: ignore
137137 return True
138138
139139 def is_in_transaction (self , conn : Connection ) -> bool :
140140 if MySQLDriverDialect ._is_mysql_connection (conn ):
141- return bool (conn .in_transaction )
141+ return bool (conn .in_transaction ) # type: ignore
142142
143143 raise UnsupportedOperationError (
144144 Messages .get_formatted ("DriverDialect.UnsupportedOperationError" , self ._driver_name ,
@@ -176,7 +176,7 @@ def get_connection_from_obj(self, obj: object) -> Any:
176176
177177 def transfer_session_state (self , from_conn : Connection , to_conn : Connection ):
178178 if MySQLDriverDialect ._is_mysql_connection (from_conn ) and MySQLDriverDialect ._is_mysql_connection (to_conn ):
179- to_conn .autocommit = from_conn .autocommit
179+ to_conn .autocommit = from_conn .autocommit # type: ignore
180180
181181 def ping (self , conn : Connection ) -> bool :
182182 return not self .is_closed (conn )
0 commit comments