pola-rs/polars · error · TypeError
Unknown comparison: {op}
Error message
Unknown comparison: {op} What it means
Error "Unknown comparison: {op}" thrown in pola-rs/polars.
Source
Thrown at py-polars/src/polars/io/iceberg/_utils.py:260
@_convert_predicate.register(Compare)
def _(a: Compare) -> Any:
op = a.ops[0]
lhs = _convert_predicate(a.left)[0]
rhs = _convert_predicate(a.comparators[0])
if isinstance(op, Gt):
return pyiceberg.expressions.GreaterThan(lhs, rhs) # type: ignore[misc, call-arg]
if isinstance(op, GtE):
return pyiceberg.expressions.GreaterThanOrEqual(lhs, rhs) # type: ignore[misc, call-arg]
if isinstance(op, Eq):
return pyiceberg.expressions.EqualTo(lhs, rhs) # type: ignore[misc, call-arg]
if isinstance(op, Lt):
return pyiceberg.expressions.LessThan(lhs, rhs) # type: ignore[misc, call-arg]
if isinstance(op, LtE):
return pyiceberg.expressions.LessThanOrEqual(lhs, rhs) # type: ignore[misc, call-arg]
else:
msg = f"Unknown comparison: {op}"
raise TypeError(msg)
@_convert_predicate.register(List)
def _(a: List) -> Any:
return [_convert_predicate(e) for e in a.elts]
def extract_field_initial_default(field: NestedField) -> pl.Series | None:
from pyiceberg.types import (
UUIDType,
)
if field.initial_default is None:
return None
value = field.initial_default
if isinstance(field.field_type, UUIDType):View on GitHub (pinned to df599052da)
When it happens
Trigger: Thrown at py-polars/src/polars/io/iceberg/_utils.py:260 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of pola-rs/polars@df599052da (2026-08-16).
Data as JSON: /api/errors/78c6df7b7ea1e3a3.
Report an issue: GitHub.