Mailing List Archive

[7.3] 48c299c13 doc: Use a raw string for regular expressions
commit 48c299c13a3b59ebad4bda1ffddad6fc75fba551
Author: Dridi Boukelmoune <dridi.boukelmoune@gmail.com>
Date: Mon Dec 4 10:45:20 2023 +0100

doc: Use a raw string for regular expressions

Since Python 3.12 unknown escape sequences trigger a warning.

diff --git a/doc/sphinx/vtc-syntax.py b/doc/sphinx/vtc-syntax.py
index cfc5a05ab..acf6f356c 100644
--- a/doc/sphinx/vtc-syntax.py
+++ b/doc/sphinx/vtc-syntax.py
@@ -38,7 +38,7 @@ import re
def parse_file(fn, cl, tl, sl):
p = False
section = ""
- resec = re.compile("\s*/?\* SECTION: ")
+ resec = re.compile(r"\s*/?\* SECTION: ")

try:
# Python3
_______________________________________________
varnish-commit mailing list
varnish-commit@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit