Fix deprecation warning regarding invalid escape sequences.

This commit is contained in:
Karthikeyan Singaravelan 2020-04-04 16:08:44 +00:00
parent 98108d0445
commit 5fc757f200
2 changed files with 2 additions and 2 deletions

View file

@ -516,7 +516,7 @@ class Field(ElementBase):
:param value: string
"""
pattern = re.compile("^\d+([|]\w+([.]\w+)*([|][^,]*)?)?(,\d+([|]\w+([.]\w+)*([|][^,]*)?)?)*$")
pattern = re.compile(r"^\d+([|]\w+([.]\w+)*([|][^,]*)?)?(,\d+([|]\w+([.]\w+)*([|][^,]*)?)?)*$")
if pattern.match(value) is not None:
self.xml.stringIds = value
else:

View file

@ -160,7 +160,7 @@ except:
return _fixed_offset_tzs[offsetmins]
_iso8601_parser = re.compile("""
_iso8601_parser = re.compile(r"""
^
(?P<year> [0-9]{4})?(?P<ymdsep>-?)?
(?P<month>[0-9]{2})?(?P=ymdsep)?