Skip to content

Changes

Summary

  1. fix "SyntaxWarning: invalid escape sequence '\('" (details)
Commit b15d2af6ed534c550a546493b5ff4c43d898e5f2 by Vadim Yanitskiy
fix "SyntaxWarning: invalid escape sequence '\('"

This is a new warning introduced in Python 3.12:

https://docs.python.org/dev/whatsnew/3.12.html#other-language-changes

Python 3 interprets string literals as Unicode strings, and so '\('
is treated as an escaped Unicode character.  Fix this by prefixing
the regexp strings with 'r' and thus converting them to raw strings.

Change-Id: I7a9f546dc7cdf9bc250516a58f35b50b46017dc3
The file was modified osmopy/osmo_interact/ctrl.py
The file was modified osmopy/obscvty.py
The file was modified osmopy/osmo_interact/vty.py