betodealmeida commented on a change in pull request #14089:
URL: https://github.com/apache/superset/pull/14089#discussion_r612026760



##########
File path: superset/db_engine_specs/mysql.py
##########
@@ -93,6 +104,21 @@ class MySQLEngineSpec(BaseEngineSpec):
 
     type_code_map: Dict[int, str] = {}  # loaded from get_datatype only if 
needed
 
+    custom_errors = {
+        INVALID_ACCESS_REGEX: (
+            __('Either the username "%(username)s" or the password is 
incorrect.'),
+            SupersetErrorType.TEST_CONNECTION_ACCESS_DENIED_ERROR,
+        ),
+        INVALID_HOSTNAME_REGEX: (
+            __('Unknown MySQL server host "%(hostname)s"'),
+            SupersetErrorType.TEST_CONNECTION_INVALID_HOSTNAME_ERROR,
+        ),
+        CONNECTION_HOST_DOWN_REGEX: (

Review comment:
       Ah, I just saw that this already existed, sorry.
   
   But I think we should call this `TEST_CONNECTION_HOST_DOWN_REGEX`, to match 
the error type.




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

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to