codeant-ai-for-open-source[bot] commented on code in PR #45070:
URL: https://github.com/apache/superset/pull/45070#discussion_r4331813161


##########
superset/db_engine_specs/clickhouse.py:
##########
@@ -681,3 +702,193 @@ def get_column_description_retry_sql(cls, sql: str) -> 
str | None:
         # bare outer SELECT to satisfy it without altering or dropping any of
         # the mutator's comments.
         return f"SELECT * FROM (\n{sql}\n) AS __superset_type_probe LIMIT 0"  
# noqa: S608
+
+    # ClickHouse never hands back a server-assigned identifier Superset could
+    # read and reuse later -- but its HTTP interface accepts a client-chosen
+    # `query_id`, and `KILL QUERY WHERE query_id = ...` accepts that same id
+    # from a second, independent connection. Minting it here needs no round
+    # trip: `has_query_id_before_execute` (the base default) runs this before
+    # the statement is sent, so the id is threaded into `execute_with_cursor`
+    # below in time to be passed to the driver.
+    @classmethod
+    def get_cancel_query_id(  # pylint: disable=unused-argument
+        cls,
+        cursor: Any,
+        query: Query,
+    ) -> str | None:
+        return str(uuid.uuid4())

Review Comment:
   ✅ **CodeAnt verified this suggestion was addressed in subsequent commits and 
marked this thread resolved** as of `7d7d54e`.
   
   `get_cancel_query_id` now returns `None` when `query.id` is `None`, so the 
chart-data cancellation stub does not mint an ID that `Database.get_df` cannot 
forward.
   
   <sub>If that's not right, unresolve this thread and CodeAnt will leave it 
open.</sub>
   
   <!-- codeant-auto-resolve-reply -->



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