pola-rs/polars · error · ValueError

Unknown call: {f!r}

Error message

Unknown call: {f!r}

What it means

Error "Unknown call: {f!r}" thrown in pola-rs/polars.

Source

Thrown at py-polars/src/polars/io/iceberg/_utils.py:219

    f = _convert_predicate(a.func)
    if f == "field":
        return args
    elif f == "scalar":
        return args[0]
    elif f in _temporal_conversions:
        # convert from polars-native i64 to ISO8601 string
        return _temporal_conversions[f](*args).isoformat()
    else:
        ref = _convert_predicate(a.func.value)[0]  # type: ignore[attr-defined]
        if f == "isin":
            return pyiceberg.expressions.In(ref, args[0])  # type: ignore[misc, call-arg]
        elif f == "is_null":
            return pyiceberg.expressions.IsNull(ref)  # type: ignore[misc]
        elif f == "is_nan":
            return pyiceberg.expressions.IsNaN(ref)  # type: ignore[misc]

    msg = f"Unknown call: {f!r}"
    raise ValueError(msg)


@_convert_predicate.register(Attribute)
def _(a: Attribute) -> Any:
    return a.attr


@_convert_predicate.register(BinOp)
def _(a: BinOp) -> Any:
    lhs = _ensure_boolean_expression(_convert_predicate(a.left))
    rhs = _ensure_boolean_expression(_convert_predicate(a.right))

    op = a.op
    if isinstance(op, BitAnd):
        return pyiceberg.expressions.And(lhs, rhs)
    if isinstance(op, BitOr):
        return pyiceberg.expressions.Or(lhs, rhs)
    else:

View on GitHub (pinned to df599052da)

When it happens

Trigger: Thrown at py-polars/src/polars/io/iceberg/_utils.py:219 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/cfe17b1813d21ebf. Report an issue: GitHub.