Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

add catches for get_schemas (#6874)

Shahmir Varqha66da8661a37d
diff --git a/marimo/_sql/engines/ibis.py b/marimo/_sql/engines/ibis.py
index eff450546e..aeb53d89ef 100644
--- a/marimo/_sql/engines/ibis.py
+++ b/marimo/_sql/engines/ibis.py
@@ -202,7 +202,6 @@ class IbisEngine(SQLConnection["SQLBackend"]):
schemas: list[Schema] = []
- # Try to get schemas, with fallback for backends that don't support catalog parameter
try:
schema_names = self._connection.list_databases(catalog=database)
except (TypeError, AttributeError) as e:
@@ -219,6 +218,14 @@ class IbisEngine(SQLConnection["SQLBackend"]):
"Backend doesn't support list_databases, using default schema"
)
schema_names = [self.default_schema or "main"]
+ except NotImplementedError:
+ LOGGER.info("Introspection is not supported for this database")
+ return []
+ except Exception:
+ LOGGER.warning(
+ "Failed to get schemas for this database", exc_info=True
+ )
+ return []
for schema_name in schema_names:
if schema_name and schema_name.lower() in meta_schemas: