[New-bugs-announce] [issue32912] Raise non-silent warning for invalid escape sequences

Emanuel Barry report at bugs.python.org
Thu Feb 22 13:34:57 EST 2018


New submission from Emanuel Barry <barry at dadadata.net>:

This is a follow-up to Issue27364.

Back in Python 3.6, a silent warning was added for all invalid escape sequences in str and bytes. It was suggested that it would remain a silent warning (which still impacts tests, while not visually annoying the average user) for two releases (3.6 and 3.7), then would be upgraded to a non-silent warning for two subsequent releases (3.8 and 3.9) before becoming a full-on syntax error. With the 3.7 feature freeze on and going, I think it's time to evaluate the approach we take for 3.8 :)

I suggest upgrading the DeprecationWarning to a SyntaxWarning, which is visible by default, for 3.8 and 3.9. I have cross-linked #27364 to this issue as well.

-Em

----------
components: Interpreter Core
messages: 312575
nosy: ebarry
priority: normal
severity: normal
stage: needs patch
status: open
title: Raise non-silent warning for invalid escape sequences
type: behavior
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32912>
_______________________________________


More information about the New-bugs-announce mailing list