cpython/Doc/whatsnew
Victor Stinner a60ddd31be
gh-98401: Invalid escape sequences emits SyntaxWarning (#99011)
A backslash-character pair that is not a valid escape sequence now
generates a SyntaxWarning, instead of DeprecationWarning.  For
example, re.compile("\d+\.\d+") now emits a SyntaxWarning ("\d" is an
invalid escape sequence), use raw strings for regular expression:
re.compile(r"\d+\.\d+"). In a future Python version, SyntaxError will
eventually be raised, instead of SyntaxWarning.

Octal escapes with value larger than 0o377 (ex: "\477"), deprecated
in Python 3.11, now produce a SyntaxWarning, instead of
DeprecationWarning. In a future Python version they will be
eventually a SyntaxError.

codecs.escape_decode() and codecs.unicode_escape_decode() are left
unchanged: they still emit DeprecationWarning.

* The parser only emits SyntaxWarning for Python 3.12 (feature
  version), and still emits DeprecationWarning on older Python
  versions.
* Fix SyntaxWarning by using raw strings in Tools/c-analyzer/ and
  wasm_build.py.
2022-11-03 17:53:25 +01:00
..
2.0.rst gh-96959: Update more HTTP links (GH-97536) 2022-09-27 14:08:11 +03:00
2.1.rst
2.2.rst docs: Change links to label refs (#98454) 2022-10-25 20:26:28 -07:00
2.3.rst gh-93738: Documentation C syntax (:c:type:<C type> -> :c:expr:<C type>) (#97768) 2022-10-05 11:01:14 -07:00
2.4.rst gh-93738: Documentation C syntax (:c:type:<C type> -> :c:expr:<C type>) (#97768) 2022-10-05 11:01:14 -07:00
2.5.rst gh-93738: Disallow pre-v3 syntax in the C domain (#97962) 2022-10-06 10:11:37 -07:00
2.6.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
2.7.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.0.rst
3.1.rst
3.2.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.3.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.4.rst gh-96959: Update more HTTP links (GH-97536) 2022-09-27 14:08:11 +03:00
3.5.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.6.rst docs: Change links to label refs (#98454) 2022-10-25 20:26:28 -07:00
3.7.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.8.rst docs: Change links to label refs (#98454) 2022-10-25 20:26:28 -07:00
3.9.rst Docs: Fix backtick errors found by sphinx-lint (#97998) 2022-10-06 18:01:30 -07:00
3.10.rst Doc: Remove title text from internal links (#98409) 2022-10-19 08:36:07 -07:00
3.11.rst fix a typo in whatsnew/3.11 (#98603) 2022-10-25 16:42:54 -07:00
3.12.rst gh-98401: Invalid escape sequences emits SyntaxWarning (#99011) 2022-11-03 17:53:25 +01:00
changelog.rst
index.rst