From c4f03e97d52d617b93f664750737ae844b12d73e Mon Sep 17 00:00:00 2001 From: Matthew Murray Date: Wed, 15 Jan 2025 20:32:38 +0000 Subject: [PATCH] update config docs, code cov --- py-polars/docs/source/reference/config.rst | 1 + py-polars/polars/config.py | 2 +- py-polars/polars/lazyframe/frame.py | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/py-polars/docs/source/reference/config.rst b/py-polars/docs/source/reference/config.rst index c190bfde5d3d..38fbeecd500c 100644 --- a/py-polars/docs/source/reference/config.rst +++ b/py-polars/docs/source/reference/config.rst @@ -12,6 +12,7 @@ Config options Config.set_ascii_tables Config.set_auto_structify Config.set_decimal_separator + Config.set_default_engine Config.set_float_precision Config.set_fmt_float Config.set_fmt_str_lengths diff --git a/py-polars/polars/config.py b/py-polars/polars/config.py index ba5d295aa27d..51205684a195 100644 --- a/py-polars/polars/config.py +++ b/py-polars/polars/config.py @@ -1456,7 +1456,7 @@ def set_expr_depth_warning(cls, limit: int) -> type[Config]: @classmethod def set_default_engine(cls, engine: Literal["cpu", "gpu"] | None) -> type[Config]: """ - Set the default engine to use the GPU. + Set which engine to use by default. Parameters ---------- diff --git a/py-polars/polars/lazyframe/frame.py b/py-polars/polars/lazyframe/frame.py index 4c7f866c6e8e..ebfb95bd7c10 100644 --- a/py-polars/polars/lazyframe/frame.py +++ b/py-polars/polars/lazyframe/frame.py @@ -2004,8 +2004,8 @@ def collect( if not (is_config_obj or engine in ("cpu", "gpu")): msg = f"Invalid engine argument {engine=}" raise ValueError(msg) - if get_default_engine() == "gpu": - is_gpu = True + if get_default_engine() == "gpu": # pragma: no cover + is_gpu = True # pragma: no cover if (streaming or background or new_streaming) and is_gpu: issue_warning( "GPU engine does not support streaming or background collection, "