mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01: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: df9898f13c261eeac2cc343569c843bc7dcaf163)
Signed-off-by: Martin Jansa <martin.jansa@gmail.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
This commit is contained in:
committed by
Steve Sakoman
parent
838a12c621
commit
d2c6c66c1e
@@ -172,8 +172,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