changeset 44817:423e20c78e6d stable

py3: pass regex as bytes
author Manuel Jacob <me@manueljacob.de>
date Tue, 16 Jun 2020 14:33:49 +0200
parents 7a4630536e53
children 9e5f598fd29b
files hgext/convert/subversion.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/convert/subversion.py	Tue Jun 16 14:32:10 2020 +0200
+++ b/hgext/convert/subversion.py	Tue Jun 16 14:33:49 2020 +0200
@@ -662,9 +662,9 @@
     def checkrevformat(self, revstr, mapname=b'splicemap'):
         """ fails if revision format does not match the correct format"""
         if not re.match(
-            r'svn:[0-9a-f]{8,8}-[0-9a-f]{4,4}-'
-            r'[0-9a-f]{4,4}-[0-9a-f]{4,4}-[0-9a-f]'
-            r'{12,12}(.*)@[0-9]+$',
+            br'svn:[0-9a-f]{8,8}-[0-9a-f]{4,4}-'
+            br'[0-9a-f]{4,4}-[0-9a-f]{4,4}-[0-9a-f]'
+            br'{12,12}(.*)@[0-9]+$',
             revstr,
         ):
             raise error.Abort(