neutron-vpnaas/neutron_vpnaas/services/vpn/device_drivers
Dongcan Ye be935a2256 Fix invalid escape sequence warning
Python 3 interprets string literals as Unicode strings,
and therefore '\d' is treated as an escaped Unicode character.

If you’re not using a raw string to express the pattern,
remember that Python also uses the backslash as an escape sequence in
string literals; if the escape sequence isn’t recognized by Python’s parser,
the backslash and subsequent character are included in the resulting string.
However, if Python would recognize the resulting sequence, the backslash
should be repeated twice. This is complicated and hard to understand,
so it’s highly recommended that you use raw strings for all but the
simplest expressions. [1]

This patch use raw string for the regular expression.

[1] https://docs.python.org/3.6/library/re.html#regular-expression-syntax

Change-Id: Ibee059af3b24896749b66d87a6691fdf40a5767a
Closes-Bug: #1871621
2020-04-08 13:00:35 +00:00
..
template Make libreswan driver work with recent versions 2018-06-22 15:29:48 +08:00
__init__.py Drop using six library 2020-01-07 06:26:03 +00:00
ipsec.py Fix invalid escape sequence warning 2020-04-08 13:00:35 +00:00
libreswan_ipsec.py Run neutron-vpn-netns-wrapper in venv 2020-02-26 02:52:19 +00:00
strongswan_ipsec.py Fix invalid escape sequence warning 2020-04-08 13:00:35 +00:00