]> git.ipfire.org Git - thirdparty/patchwork.git/commitdiff
Resolve Python 3.6 warnings
authorStephen Finucane <stephen@that.guru>
Sun, 24 Jun 2018 19:55:55 +0000 (20:55 +0100)
committerStephen Finucane <stephen@that.guru>
Fri, 26 Oct 2018 10:02:22 +0000 (11:02 +0100)
DeprecationWarning: invalid escape sequence \d

Signed-off-by: Stephen Finucane <stephen@that.guru>
Reviewed-by: Daniel Axtens <dja@axtens.net>
Signed-off-by: Daniel Axtens <dja@axtens.net>
(cherry picked from commit 67c76281c25efd88dfda1a86f4b277e8f1bfbb53)

patchwork/parser.py

index a2db40373039f7d96b860281678795865a7e694c..40a80f267e6525160c0234ae27c7149bd5e0a68b 100644 (file)
@@ -486,7 +486,7 @@ def parse_version(subject, subject_prefixes):
     Returns:
         version if found, else 1
     """
-    regex = re.compile('^[vV](\d+)$')
+    regex = re.compile(r'^[vV](\d+)$')
     m = _find_matching_prefix(subject_prefixes, regex)
     if m:
         return int(m.group(1))