Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions python/cudf_polars/cudf_polars/dsl/translate.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,9 +301,11 @@ def _drop_dyn_pred_hints(
):
left = _drop_dyn_pred_hints(translator, node.left, schema)
right = _drop_dyn_pred_hints(translator, node.right, schema)
if left is None:
return right # pragma: no cover
if right is None:
# Which branch is taken depends on where the dynamic predicate lands in
# the AND tree, which is nondeterministic.
if left is None: # pragma: no cover
return right
if right is None: # pragma: no cover
return left
return expr.BinOp(
DataType(translator.visitor.get_dtype(n)),
Expand Down
2 changes: 1 addition & 1 deletion python/cudf_polars/tests/test_filter.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# SPDX-FileCopyrightText: Copyright (c) 2024-2026, NVIDIA CORPORATION & AFFILIATES.
# SPDX-FileCopyrightText: Copyright (c) 2024-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
from __future__ import annotations

Expand Down
Loading