Skip to content

Commit 12da76c

Browse files
author
Ralf Schlatterbeck
committed
Seems like not all versions of postgres-drivers contain the string "ERROR"...
...in error-messages. In that case creating the database (when it already exists) fails. This fixes the problem for me.
1 parent 56dbc42 commit 12da76c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

roundup/backends/back_postgresql.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#$Id: back_postgresql.py,v 1.38 2007-06-21 07:35:50 schlatterbeck Exp $
1+
#$Id: back_postgresql.py,v 1.39 2007-08-09 08:58:42 schlatterbeck Exp $
22
#
33
# Copyright (c) 2003 Martynas Sklyzmantas, Andrey Lebedev <[email protected]>
44
#
@@ -79,7 +79,7 @@ def pg_command(cursor, command):
7979
response = str(err).split('\n')[0]
8080
if response.find('FATAL') != -1:
8181
raise RuntimeError, response
82-
elif response.find('ERROR') != -1:
82+
else:
8383
msgs = [
8484
'is being accessed by other users',
8585
'could not serialize access due to concurrent update',

0 commit comments

Comments
 (0)