sadpandajoe commented on code in PR #35969:
URL: https://github.com/apache/superset/pull/35969#discussion_r2501596866


##########
superset/commands/chart/data/get_data_command.py:
##########
@@ -48,8 +49,13 @@ def run(self, **kwargs: Any) -> dict[str, Any]:
         except CacheLoadError as ex:
             raise ChartDataCacheLoadError(ex.message) from ex
 
+        # Skip error check for query-only requests - errors are returned in 
payload
+        # This allows View Query modal to display validation errors
         for query in payload["queries"]:
-            if query.get("error"):
+            if (
+                query.get("error")
+                and self._query_context.result_type != 
ChartDataResultType.QUERY
+            ):

Review Comment:
   1. The logic is correct: QUERY is the special case, all others should fail 
fast
     2. More maintainable than positive logic - new result types will 
automatically get safe default behavior
     3. Comprehensive test coverage confirms it works for QUERY, FULL, and 
RESULTS types



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