[New-bugs-announce] [issue16007] Improved Error message for failing re expressions

Ling Li report at bugs.python.org
Sun Sep 23 18:14:28 CEST 2012

New submission from Ling Li:


I would like to make a small improvement to the exception raised when _compile() function fails with exception on line 245. 

Please see attached amended file. The line of code is amended from: 

    raise error, v # invalid expression


    raise error, r'%s with pattern: %s' % (v, pattern) # invalid expression

As this is my first contribution, please let me know if this is the correct procedure to submit changes.

Kind regards,

components: Regular Expressions
files: re.py
messages: 171051
nosy: ezio.melotti, lingster, mrabarnett
priority: normal
severity: normal
status: open
title: Improved Error message for failing re expressions
type: enhancement
versions: Python 2.7
Added file: http://bugs.python.org/file27266/re.py

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list