From 6577df9ef9a4ff596044e7f8fb7f766e83e5607a Mon Sep 17 00:00:00 2001 From: antti_haapala Date: Fri, 11 Apr 2014 19:38:07 +0000 Subject: [PATCH] added an SSL related connection error --- lib/sqlalchemy/dialects/postgresql/psycopg2.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/sqlalchemy/dialects/postgresql/psycopg2.py b/lib/sqlalchemy/dialects/postgresql/psycopg2.py index b901bcc56c..268a89724b 100644 --- a/lib/sqlalchemy/dialects/postgresql/psycopg2.py +++ b/lib/sqlalchemy/dialects/postgresql/psycopg2.py @@ -496,7 +496,9 @@ class PGDialect_psycopg2(PGDialect): 'cursor already closed', # not sure where this path is originally from, it may # be obsolete. It really says "losed", not "closed". - 'losed the connection unexpectedly' + 'losed the connection unexpectedly', + # this can occur in newer SSL + 'connection has been closed unexpectedly' ]: idx = str_e.find(msg) if idx >= 0 and '"' not in str_e[:idx]: -- 2.47.3