diff --git a/trytond/trytond/backend/postgresql/database.py b/trytond/trytond/backend/postgresql/database.py index ab4d7169a2..7c7420ac62 100644 --- a/trytond/trytond/backend/postgresql/database.py +++ b/trytond/trytond/backend/postgresql/database.py @@ -264,7 +264,7 @@ class Database(DatabaseInterface): for count in range(retry, -1, -1): try: conn = self._connpool.getconn() - except PoolError: + except (PoolError, DatabaseOperationalError): if count and not self._connpool.closed: logger.info('waiting a connection') time.sleep(1)