changeset 42951:04c6de38734d

py3: byte-prefix sanitisation regexes in phabricator.py So it doesn't die with "TypeError: cannot use a string pattern on a bytes-like object". Differential Revision: https://phab.mercurial-scm.org/D6863
author Ian Moody <moz-ian@perix.co.uk>
date Tue, 17 Sep 2019 21:06:07 +0100
parents 6fb281f39c25
children 44be33cf7a57
files hgext/phabricator.py
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/phabricator.py	Wed Sep 18 00:20:43 2019 +0100
+++ b/hgext/phabricator.py	Tue Sep 17 21:06:07 2019 +0100
@@ -136,8 +136,8 @@
 
     def sanitiserequest(request):
         request.body = re.sub(
-            r'cli-[a-z0-9]+',
-            r'cli-hahayouwish',
+            br'cli-[a-z0-9]+',
+            br'cli-hahayouwish',
             request.body
         )
         return request