]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
oeqa/gitarchive: Fix syntax warning
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 3 Dec 2024 13:43:30 +0000 (13:43 +0000)
committerSteve Sakoman <steve@sakoman.com>
Mon, 10 Feb 2025 16:06:16 +0000 (08:06 -0800)
The backslash characters cause syntax warnings, mark the strings are raw
to avoid this.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
(cherry picked from commit f717f61a37ed83618d054fc4017b5f5386fb2e3c)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
meta/lib/oeqa/utils/gitarchive.py

index a826646059a523bbc3854abcf955e65681ce79eb..7e1d5057482f76ad584394026b26fc7700d9a656 100644 (file)
@@ -146,7 +146,7 @@ def expand_tag_strings(repo, name_pattern, msg_subj_pattern, msg_body_pattern,
         keyws['tag_number'] = '{tag_number}'
         tag_re = format_str(name_pattern, keyws)
         # Replace parentheses for proper regex matching
-        tag_re = tag_re.replace('(', '\(').replace(')', '\)') + '$'
+        tag_re = tag_re.replace('(', r'\(').replace(')', r'\)') + '$'
         # Inject regex group pattern for 'tag_number'
         tag_re = tag_re.format(tag_number='(?P<tag_number>[0-9]{1,5})')