mirror of
https://github.com/apache/superset.git
synced 2026-07-16 19:55:39 +00:00
fix: annotate remaining new locals per type-hint rule
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -3886,7 +3886,7 @@ class ExploreMixin: # pylint: disable=too-many-public-methods
|
||||
}:
|
||||
# Native UUID columns report GenericDataType.STRING but
|
||||
# reject LIKE/ILIKE without a cast (see issue #41795)
|
||||
needs_string_cast_for_like = (
|
||||
needs_string_cast_for_like: bool = (
|
||||
target_generic_type != GenericDataType.STRING
|
||||
or is_uuid_native_type(col_type)
|
||||
)
|
||||
|
||||
@@ -3761,7 +3761,7 @@ def test_like_filter_on_uuid_column_casts_to_string(
|
||||
is_timeseries=False,
|
||||
orderby=[],
|
||||
)
|
||||
whereclause = result.sqla_query.whereclause
|
||||
whereclause: ColumnElement = result.sqla_query.whereclause
|
||||
assert any(isinstance(node, Cast) for node in iterate(whereclause)), (
|
||||
f"Expected a Cast node in the filter expression: {whereclause}"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user