mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01:00
scripts: python 3.12 regex
All the regexes throw a warning like this:
WARNING: scripts/lib/recipetool/create_buildsys.py:140:
SyntaxWarning: invalid escape sequence '\s'
proj_re = re.compile('project\s*\(([^)]*)\)', re.IGNORECASE)
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: 24b0ba00d4f0b4d9834f7693ecb6032dfc534a80)
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
97eebe59d7
commit
605ef6f5a2
@@ -29,7 +29,7 @@ for arg in sys.argv[1:]:
|
||||
args.append(arg)
|
||||
|
||||
# Regex for removing version specs after dependency items
|
||||
verregex = re.compile(' \([=<>]* [^ )]*\)')
|
||||
verregex = re.compile(r' \([=<>]* [^ )]*\)')
|
||||
|
||||
pkg = ""
|
||||
ver = ""
|
||||
|
||||
Reference in New Issue
Block a user