[issue28128] Improve the warning message for invalid escape sequences
Tim Graham
report at bugs.python.org
Thu Sep 15 19:43:27 EDT 2016
Tim Graham added the comment:
I hope the message can be improved for Python 3.6 as the warnings I see when running Django's test suite are rather useless to help find and fix the issues:
cpython/Lib/importlib/_bootstrap.py:205: DeprecationWarning: invalid escape sequence '\:'
Grepping for these characters patterns to try to figure out where they come from is quite difficult.
I did track down one instance in a docstring:
https://github.com/django/django/blob/82f8996785751c413e3b4ac12bf387f781c200d8/django/contrib/gis/maps/google/__init__.py#L41
Is the correct resolution to add an r prefix to the string? It could be nice if the release notes contained some guidance on that.
----------
nosy: +Tim.Graham
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28128>
_______________________________________
More information about the Python-bugs-list
mailing list