aboutsummaryrefslogtreecommitdiffstats
path: root/layerindex
diff options
context:
space:
mode:
authorRobert Yang <liezhi.yang@windriver.com>2018-04-17 16:43:51 +0800
committerPaul Eggleton <paul.eggleton@linux.intel.com>2018-04-24 10:13:19 +1200
commit51047ec58cd4d6a315ecf11f4defd69bd08e779e (patch)
tree928565a7ee3333c6808cc6990e36a03e7a68abd5 /layerindex
parentf7e63f1814234dd6f9b92bbabafb8a42319bf82c (diff)
downloadopenembedded-core-contrib-51047ec58cd4d6a315ecf11f4defd69bd08e779e.tar.gz
openembedded-core-contrib-51047ec58cd4d6a315ecf11f4defd69bd08e779e.tar.bz2
openembedded-core-contrib-51047ec58cd4d6a315ecf11f4defd69bd08e779e.zip
update.py: print failed layers summary in the end
This makes it easy to see which layers failed. For example: ERROR: Failed layers on branch master: openembedded-core meta-python Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'layerindex')
-rwxr-xr-xlayerindex/update.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/layerindex/update.py b/layerindex/update.py
index e4ca7b6fd4..44a7b903d4 100755
--- a/layerindex/update.py
+++ b/layerindex/update.py
@@ -319,6 +319,7 @@ def main():
# unreliable due to leaking memory (we're using bitbake internals in a manner in which
# they never get used during normal operation).
last_rev = {}
+ failed_layers = {}
for branch in branches:
# If layer_A depends(or recommends) on layer_B, add layer_B before layer_A
deps_dict_all = {}
@@ -384,9 +385,12 @@ def main():
# If nothing changed after a run then some dependencies couldn't be resolved
if operator.eq(deps_dict_all_copy, deps_dict_all):
logger.warning("Cannot find required collections on branch %s:" % branch)
+ layer_names = []
for layer, value in deps_dict_all.items():
logger.error('%s: %s' % (layer.name, value['requires']))
+ layer_names.append(layer.name)
logger.warning("Known collections on branch %s: %s" % (branch, collections))
+ failed_layers[branch] = layer_names
break
for layer in layerquery_sorted:
@@ -427,6 +431,11 @@ def main():
# Interrupted by user, break out of loop
logger.info('Update interrupted, exiting')
sys.exit(254)
+ if failed_layers:
+ print()
+ for branch, err_msg_list in failed_layers.items():
+ logger.error("Failed layers on branch %s: %s" % (branch, " ".join(err_msg_list)))
+ print()
finally:
utils.unlock_file(lockfile)