mirror of
https://git.yoctoproject.org/poky
synced 2026-04-17 18:32:12 +02:00
license.py: avoid deprecated ast.Str
* it's deprecated since python-3.12 and removed in 3.14 causing:
openembedded-core/meta/lib/oe/license.py', lineno: 176, function: visit
0172:
0173: LicenseVisitor.__init__(self)
0174:
0175: def visit(self, node):
*** 0176: if isinstance(node, ast.Str):
0177: lic = node.s
0178:
0179: if license_ok(self._canonical_license(self._d, lic),
0180: self._dont_want_licenses) == True:
Exception: AttributeError: module 'ast' has no attribute 'Str'
(From OE-Core rev: 1eb2137324202107baa5cadcfdd682629a9cc269)
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
e91bc261dc
commit
44fbbe97c6
@@ -173,8 +173,8 @@ class ManifestVisitor(LicenseVisitor):
|
||||
LicenseVisitor.__init__(self)
|
||||
|
||||
def visit(self, node):
|
||||
if isinstance(node, ast.Str):
|
||||
lic = node.s
|
||||
if isinstance(node, ast.Constant):
|
||||
lic = node.value
|
||||
|
||||
if license_ok(self._canonical_license(self._d, lic),
|
||||
self._dont_want_licenses) == True:
|
||||
|
||||
Reference in New Issue
Block a user