aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2016-03-30 20:55:42 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-03-30 21:23:54 +0100
commita0860e308645f17dbf4b9005b2fc0e9869d730bf (patch)
tree743d37a499bb4df9800ec45d2e4529b0ab8efabb
parentaedef9d6a585db9c1289f6117e72bdb576a1a304 (diff)
downloadopenembedded-core-contrib-a0860e308645f17dbf4b9005b2fc0e9869d730bf.tar.gz
openembedded-core-contrib-a0860e308645f17dbf4b9005b2fc0e9869d730bf.tar.bz2
openembedded-core-contrib-a0860e308645f17dbf4b9005b2fc0e9869d730bf.zip
sanity.bbclass: Use pythonexception to raise real exceptions without backtraces
If the sanity code encounters a version change is doesn't understand, the current output is unreadable and confusing for the user, particularly due to the presence of the backtrace. Use improved functionality in bitbake to improve this and correctly pass python exceptions around. [YOCTO #9291] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/sanity.bbclass4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index a400bcadd0..662f764533 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -563,10 +563,10 @@ def sanity_check_conffiles(status, d):
d.getVar(current_version, True) != d.getVar(required_version, True):
success = True
try:
- bb.build.exec_func(func, d)
+ bb.build.exec_func(func, d, pythonexception=True)
except NotImplementedError as e:
success = False
- status.addresult(e.msg)
+ status.addresult(str(e))
if success:
status.reparse = True