mirror of
https://git.yoctoproject.org/poky
synced 2026-06-03 01:40:07 +00:00
meta/lib/patchtest: python 3.12 regex
Python 3 interprets string literals as Unicode strings, and therefore \s is treated as an escaped Unicode character which is not correct. Declaring the RegEx pattern as a raw string instead of unicode is required for Python 3. (From OE-Core rev: 329a555f7b8f00c648c44b01f423e6da33a46245) Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
7f2755daca
commit
fe58da1393
@@ -34,8 +34,8 @@ class PatchtestOEError(Exception):
|
||||
class Base(unittest.TestCase):
|
||||
# if unit test fails, fail message will throw at least the following JSON: {"id": <testid>}
|
||||
|
||||
endcommit_messages_regex = re.compile('\(From \w+-\w+ rev:|(?<!\S)Signed-off-by|(?<!\S)---\n')
|
||||
patchmetadata_regex = re.compile('-{3} \S+|\+{3} \S+|@{2} -\d+,\d+ \+\d+,\d+ @{2} \S+')
|
||||
endcommit_messages_regex = re.compile(r'\(From \w+-\w+ rev:|(?<!\S)Signed-off-by|(?<!\S)---\n')
|
||||
patchmetadata_regex = re.compile(r'-{3} \S+|\+{3} \S+|@{2} -\d+,\d+ \+\d+,\d+ @{2} \S+')
|
||||
|
||||
|
||||
@staticmethod
|
||||
|
||||
Reference in New Issue
Block a user