Skip to content

Commit b0e2e8a

Browse files
committed
Python 3.7 doesn't work with ur"" strings - syntax error
1 parent 2eb33a3 commit b0e2e8a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tools/build.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -657,7 +657,7 @@ def copy_and_fix_pyx_files():
657657
shutil.copy("../../src/%s" % mainfile_original, "./%s" % mainfile_newname)
658658
with open("./%s" % mainfile_newname, "rb") as fo:
659659
content = fo.read().decode("utf-8")
660-
(content, subs) = re.subn(ur"^include \"handlers/",
660+
(content, subs) = re.subn(u"^include \"handlers/",
661661
u"include \"",
662662
content,
663663
flags=re.MULTILINE)
@@ -686,7 +686,7 @@ def copy_and_fix_pyx_files():
686686
# Do not remove the newline - so that line numbers
687687
# are exact with originals.
688688
(content, subs) = re.subn(
689-
ur"^include[\t ]+[\"'][^\"'\n\r]+[\"'][\t ]*",
689+
u"^include[\\t ]+[\"'][^\"'\\n\\r]+[\"'][\\t ]*",
690690
u"",
691691
content,
692692
flags=re.MULTILINE)

0 commit comments

Comments
 (0)