misc: fix warnings about regexps (#72941)

This commit is contained in:
Benjamin Dauvergne 2023-01-11 11:50:14 +01:00
parent 72acb97eff
commit e52694fd31
1 changed files with 3 additions and 3 deletions

View File

@ -171,11 +171,11 @@ def adresse(individu):
class PersonSearch(object):
EMAIL_RE = re.compile(
'^[a-zA-Z0-9.+_-]*@[a-zA-Z0-9.+_-]*$')
r'^[a-zA-Z0-9.+_-]*@[a-zA-Z0-9.+_-]*$')
DATE_RE1 = re.compile(
'^(?:(?P<year>\d\d|\d\d\d\d)(?:-(?P<month>\d{1,2})(?:-(?P<day>\d{1,2}))?)?)$')
r'^(?:(?P<year>\d\d|\d\d\d\d)(?:-(?P<month>\d{1,2})(?:-(?P<day>\d{1,2}))?)?)$')
DATE_RE2 = re.compile(
'^(?:(?:(?:(?P<day>\d{1,2})/)?(?P<month>\d{1,2})/)?(?P<year>\d\d|\d\d\d\d))$')
r'^(?:(?:(?:(?P<day>\d{1,2})/)?(?P<month>\d{1,2})/)?(?P<year>\d\d|\d\d\d\d))$')
@classmethod
def match_birthdate(cls, birthdate):