This is an automated email from the ASF dual-hosted git repository.
fokko pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/iceberg-python.git
The following commit(s) were added to refs/heads/main by this push:
new a276112 sql-catalog: Default `create_engine` echo to `False` (#360)
a276112 is described below
commit a276112e12a481c5f461a46571b4554b74a67586
Author: Kevin Liu <[email protected]>
AuthorDate: Sun Feb 4 13:41:45 2024 -0800
sql-catalog: Default `create_engine` echo to `False` (#360)
* default create_engine echo to False
* Update pyiceberg/catalog/sql.py
Co-authored-by: Fokko Driesprong <[email protected]>
---------
Co-authored-by: Fokko Driesprong <[email protected]>
---
pyiceberg/catalog/sql.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/pyiceberg/catalog/sql.py b/pyiceberg/catalog/sql.py
index 8a02b20..9436e20 100644
--- a/pyiceberg/catalog/sql.py
+++ b/pyiceberg/catalog/sql.py
@@ -101,7 +101,8 @@ class SqlCatalog(Catalog):
if not (uri_prop := self.properties.get("uri")):
raise NoSuchPropertyException("SQL connection URI is required")
- self.engine = create_engine(uri_prop, echo=True)
+ echo = bool(self.properties.get("echo", False))
+ self.engine = create_engine(uri_prop, echo=echo)
self._ensure_tables_exist()