bito-code-review[bot] commented on code in PR #44718:
URL: https://github.com/apache/superset/pull/44718#discussion_r4119518679


##########
docs/user_docs_versioned_docs/version-6.1.0/databases/supported/apache-doris.mdx:
##########
@@ -161,3 +161,11 @@ export const databaseInfo = {
 };
 
 <DatabasePage name="Apache Doris" database={databaseInfo} />
+
+### TLS connections

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>Inconsistent heading level</b></div>
   <div id="fix">
   
   This section uses `###` while the equivalent `TLS connections` section in 
`mysql.mdx` (line 195), documenting the same `MySQLEngineSpec` TLS behavior 
that `DorisEngineSpec` inherits, uses `##`. Both are top-level sections 
directly after `<DatabasePage>` with no parent heading, so the levels should 
match for consistent navigation. Change to `## TLS connections`.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #5e217e</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



##########
superset/db_engine_specs/doris.py:
##########
@@ -276,8 +311,64 @@ class DorisEngineSpec(MySQLEngineSpec):
             SupersetErrorType.SYNTAX_ERROR,
             {},
         ),
+        DORIS_SYNTAX_ERROR_REGEX: (
+            _(
+                'Please check your query for syntax errors near 
"%(server_error)s". '
+                "Then, try running your query again."
+            ),
+            SupersetErrorType.SYNTAX_ERROR,
+            {},
+        ),
+        TABLE_DOES_NOT_EXIST_REGEX: (
+            _('The table "%(table_name)s" does not exist.'),
+            SupersetErrorType.TABLE_DOES_NOT_EXIST_ERROR,
+            {},
+        ),
+        SCHEMA_DOES_NOT_EXIST_REGEX: (
+            _('The schema "%(schema_name)s" does not exist.'),
+            SupersetErrorType.SCHEMA_DOES_NOT_EXIST_ERROR,
+            {},
+        ),
+        COLUMN_DOES_NOT_EXIST_REGEX: (
+            _('We can\'t seem to resolve the column "%(column_name)s".'),
+            SupersetErrorType.COLUMN_DOES_NOT_EXIST_ERROR,
+            {},
+        ),
     }
 
+    @classmethod
+    def build_sqlalchemy_uri(
+        cls,
+        parameters: BasicParametersType,
+        encrypted_extra: Optional[dict[str, str]] = None,
+    ) -> str:
+        # Keep explicit hostname verification when rebuilding an encrypted URI.
+        if parameters.get("query", {}).get("ssl_mode") == "VERIFY_IDENTITY":

Review Comment:
   <div>
   
   
   <div id="suggestion">
   <div id="issue"><b>TLS mode magic strings</b></div>
   <div id="fix">
   
   TLS mode strings `"VERIFY_IDENTITY"`, `"REQUIRED"`, `"VERIFY_CA"` are 
repeated as bare literals across `build_sqlalchemy_uri` (line 346), 
`get_parameters_from_uri` (lines 363, 368) and `encryption_parameters` (line 
134). These encode security-relevant connection semantics; a typo or drift 
between the branches silently changes TLS strength. Consider named constants 
shared with `mysql.py`.
   </div>
   
   
   </div>
   
   
   
   
   <small><i>Code Review Run #5e217e</i></small>
   </div>
   
   ---
   Should Bito avoid suggestions like this for future reviews? (<a 
href=https://alpha.bito.ai/home/ai-agents/review-rules>Manage Rules</a>)
   - [ ] Yes, avoid them



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


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

Reply via email to