From b4b50ac4bd0860e77f239a8df3b2f6aa00958df8 Mon Sep 17 00:00:00 2001 From: Taha Yassine Kraiem Date: Thu, 15 Sep 2022 20:47:49 +0100 Subject: [PATCH] feat(chalice): fixed pg_client --- api/chalicelib/utils/pg_client.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/chalicelib/utils/pg_client.py b/api/chalicelib/utils/pg_client.py index 1ec1f2a19..8b9001649 100644 --- a/api/chalicelib/utils/pg_client.py +++ b/api/chalicelib/utils/pg_client.py @@ -20,7 +20,7 @@ PG_CONFIG = dict(_PG_CONFIG) if config("pg_timeout", cast=int, default=0) > 0: PG_CONFIG["options"] = f"-c statement_timeout={config('pg_timeout', cast=int) * 1000}" -logging.info(f">PG_POOL:{config('PG_POOL', cast=bool, default=None)}") +logging.info(f">PG_POOL:{config('PG_POOL', default=None)}") class ORThreadedConnectionPool(psycopg2.pool.ThreadedConnectionPool): @@ -44,7 +44,7 @@ class ORThreadedConnectionPool(psycopg2.pool.ThreadedConnectionPool): except psycopg2.pool.PoolError as e: if str(e) == "trying to put unkeyed connection": print("!!! trying to put unkeyed connection") - print(f"env-PG_POOL:{config('PG_POOL', cast=bool, default=None)}") + print(f"env-PG_POOL:{config('PG_POOL', default=None)}") return raise e