summaryrefslogtreecommitdiffstats
path: root/lib/bb/ui/crumbs
diff options
context:
space:
mode:
authorCristiana Voicu <cristiana.voicu@intel.com>2013-11-01 11:18:45 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2013-11-01 17:52:23 +0000
commita5abd1826f34e6a7eefa837620b846e9b62ae758 (patch)
treef35fd6b39a5992b8f6eaa62dc1bfd989141a7bcc /lib/bb/ui/crumbs
parent17d8ef0b813a05c231e3dbe6e8bc82a4a9b1d2f8 (diff)
downloadopenembedded-core-contrib-a5abd1826f34e6a7eefa837620b846e9b62ae758.tar.gz
hob: populate error_msg when hob receives a CommandFailed event
When Hob receives a bb.command.CommandFailed event, it doesn't show any error, because the error_msg is empty. If so, it is hard to detect the issue, because Hob continues to run till it blocks because of an information gap. [YOCTO #5097] Signed-off-by: Cristiana Voicu <cristiana.voicu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/bb/ui/crumbs')
-rw-r--r--lib/bb/ui/crumbs/hobeventhandler.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/bb/ui/crumbs/hobeventhandler.py b/lib/bb/ui/crumbs/hobeventhandler.py
index 393c258e46..817f638189 100644
--- a/lib/bb/ui/crumbs/hobeventhandler.py
+++ b/lib/bb/ui/crumbs/hobeventhandler.py
@@ -98,6 +98,7 @@ class HobHandler(gobject.GObject):
self.server = server
self.error_msg = ""
+ self.lastCommand = ""
self.initcmd = None
self.parsing = False
@@ -112,6 +113,7 @@ class HobHandler(gobject.GObject):
self.generating = False
def runCommand(self, commandline):
+ self.lastCommand = commandline[0]
try:
result, error = self.server.runCommand(commandline)
if error:
@@ -251,6 +253,10 @@ class HobHandler(gobject.GObject):
self.current_phase = None
self.run_next_command()
elif isinstance(event, bb.command.CommandFailed):
+ if self.error_msg == "":
+ self.error_msg = "The command \"" + self.lastCommand
+ self.error_msg += "\" was sent to bitbake server but it failed. Please"
+ self.error_msg += " check the code executed by this command in bitbake."
self.commands_async = []
self.display_error()
elif isinstance(event, (bb.event.ParseStarted,