fix: improve error type on parse error (#33048)

(cherry picked from commit ed0cd5e7b0)
This commit is contained in:
JUST.in DO IT
2025-04-09 09:52:15 -07:00
committed by Michael S. Molina
parent f85f3f8b56
commit e0e2d329e0

View File

@@ -272,7 +272,7 @@ class ParsedQuery:
logger.warning("Unable to parse SQL (%s): %s", self._dialect, self.sql)
raise SupersetSecurityException(
SupersetError(
error_type=SupersetErrorType.QUERY_SECURITY_ACCESS_ERROR,
error_type=SupersetErrorType.INVALID_SQL_ERROR,
message=__(
"You may have an error in your SQL statement. {message}"
).format(message=ex.error.message),