diff --git a/docs/basics/dataframe_conversion.md b/docs/basics/dataframe_conversion.md index a4753a033..bdf803a23 100644 --- a/docs/basics/dataframe_conversion.md +++ b/docs/basics/dataframe_conversion.md @@ -53,7 +53,9 @@ which implements `__arrow_c_stream__`: def df_to_polars(df_native: Any) -> pl.DataFrame: if hasattr(df_native, "__arrow_c_stream__"): return nw.from_arrow(df_native, native_namespace=pl).to_native() - msg = f"Expected object which implements '__arrow_c_stream__' got: {type(df)}" + msg = ( + f"Expected object which implements '__arrow_c_stream__' got: {type(df_native)}" + ) raise TypeError(msg) diff --git a/utils/generate_backend_completeness.py b/utils/generate_backend_completeness.py index 2ab8d2187..397c8e4d6 100644 --- a/utils/generate_backend_completeness.py +++ b/utils/generate_backend_completeness.py @@ -31,9 +31,10 @@ class Backend(NamedTuple): MODULES = ["dataframe", "series", "expr"] BACKENDS = [ - Backend(name="pandas-like", module="_pandas_like", type_=BackendType.EAGER), Backend(name="arrow", module="_arrow", type_=BackendType.EAGER), Backend(name="dask", module="_dask", type_=BackendType.LAZY), + Backend(name="duckdb", module="_duckdb", type_=BackendType.LAZY), + Backend(name="pandas-like", module="_pandas_like", type_=BackendType.EAGER), Backend(name="spark-like", module="_spark_like", type_=BackendType.LAZY), ] @@ -55,6 +56,7 @@ def parse_module(module_name: str, backend: str, nw_class_name: str) -> list[str inspect.isclass(c) and c.__name__.endswith(nw_class_name) and not c.__name__.startswith("Compliant") # Exclude protocols + and not c.__name__.startswith("DuckDBInterchange") ), )