diff mbox series

[v2] data: Add exception details if build_dependencies catches one

Message ID bdc93bfc2de6fd284f4e7a8fe17463d7709d867c.1773843391.git.joerg.sommer@navimatix.de
State New
Headers show
Series [v2] data: Add exception details if build_dependencies catches one | expand

Commit Message

Jörg Sommer March 18, 2026, 2:16 p.m. UTC
From: Jörg Sommer <joerg.sommer@navimatix.de>

Without this information, you'll only get messages like this, which don't
indicate what might be wrong:

    WARNING: ….bb: Exception during build_dependencies for do_patch:00:17
    WARNING: ….bb: Error during finalise of ….bb
    ERROR: ParseError in None: Not all recipes parsed, parser thread killed/died? Exiting.
    ERROR: Parsing halted due to errors, see error messages above

Signed-off-by: Jörg Sommer <joerg.sommer@navimatix.de>
---
 lib/bb/data.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/lib/bb/data.py b/lib/bb/data.py
index 061e63386..5fdcdb04a 100644
--- a/lib/bb/data.py
+++ b/lib/bb/data.py
@@ -367,7 +367,7 @@  def build_dependencies(key, keys, mod_funcs, shelldeps, varflagsexcl, ignored_va
     except bb.parse.SkipRecipe:
         raise
     except Exception as e:
-        bb.warn("Exception during build_dependencies for %s" % key)
+        bb.warn("Exception during build_dependencies for %s: %s" % (key, repr(e)))
         raise
     return frozenset(deps), value
     #bb.note("Variable %s references %s and calls %s" % (key, str(deps), str(execs)))