Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix SyntaxWarning/DeprecationWarning
This is a `DeprecationWarning` in Python<3.12 and a `SyntaxWarning` in Python>=3.12 since `\Z` is an invalid escape sequence. In every case, this should be made a raw string as also described in the according [change note]: 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. [change note]: https://docs.python.org/3.12/whatsnew/3.12.html#other-language-changes
- Loading branch information