From 7f340def58ff50292b763a381d17b87e24e19648 Mon Sep 17 00:00:00 2001 From: Nick Crews Date: Thu, 14 Sep 2023 14:30:54 -0800 Subject: [PATCH] docs: import ibis in doctests This was failing to render in the reference sections of the docs. --- ibis/backends/base/__init__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ibis/backends/base/__init__.py b/ibis/backends/base/__init__.py index be83b4b2bb4d..ac3702776afe 100644 --- a/ibis/backends/base/__init__.py +++ b/ibis/backends/base/__init__.py @@ -1170,13 +1170,13 @@ def connect(resource: Path | str, **kwargs: Any) -> BaseBackend: The general pattern for `ibis.connect` is ```python - ibis.connect("backend://connection-parameters") + con = ibis.connect("backend://connection-parameters") ``` With many backends that looks like ```python - ibis.connect("backend://user:password@host:port/database") + con = ibis.connect("backend://user:password@host:port/database") ``` See the connection syntax for each backend for details about URL connection @@ -1193,6 +1193,7 @@ def connect(resource: Path | str, **kwargs: Any) -> BaseBackend: -------- Connect to an in-memory DuckDB database: + >>> import ibis >>> con = ibis.connect("duckdb://") Connect to an on-disk SQLite database: