Skip to contentSkip to conversation

checklayer: remove reference to undefined class

PATCH New Anuj Mittal 1 participant 1 message Mar 15, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 checklayer: remove reference to undefined class

LayerError doesn't exist and will lead to an error when this failure code path is hit.

---
 scripts/lib/checklayer/__init__.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/lib/checklayer/__init__.py +2 -2
index 6395261..288c457 100644
@@ -42,8 +42,8 @@ def _get_layer_collections(layer_path, lconf=None, data=None):
     ldata.setVar('LAYERDIR', layer_path)
     try:
         ldata = bb.parse.handle(lconf, ldata, include=True)
-    except BaseException as exc:
-        raise LayerError(exc)
+    except:
+        raise RuntimeError("Parsing of layer.conf from layer: %s failed" % layer_path)
     ldata.expandVarref('LAYERDIR')
 
     collections = (ldata.getVar('BBFILE_COLLECTIONS') or '').split()
Signature · 1 line
2.7.4