Project

General

Profile

« Previous | Next » 

Revision 3414

sql.py: run_query(): Exception parsing: Remove PL/Python prefix from exception message so that the regexps can match at the beginning of the message

View differences:

sql.py
508 508
            else: return run() # don't need savepoint if cached
509 509
        except Exception, e:
510 510
            msg = strings.ustr(e.args[0])
511
            msg = re.sub(r'^PL/Python: \w+: ', r'', msg)
511 512
            
512 513
            match = re.match(r'^duplicate key value violates unique constraint '
513 514
                r'"(.+?)"', msg)

Also available in: Unified diff