[oe-commits] [bitbake] branch master-next updated: depexp: Close UI with error message on NoProvider event
git at git.openembedded.org
git at git.openembedded.org
Mon Oct 10 08:50:42 UTC 2016
rpurdie pushed a commit to branch master-next
in repository bitbake.
The following commit(s) were added to refs/heads/master-next by this push:
new 21defce depexp: Close UI with error message on NoProvider event
21defce is described below
commit 21defced67d921d0710752832c76ff63728d8d8b
Author: Jussi Kukkonen <jussi.kukkonen at intel.com>
AuthorDate: Mon Oct 10 11:30:04 2016 +0300
depexp: Close UI with error message on NoProvider event
Without this the UI just sits there doing nothing. Showing an
infobar in-UI would be nicer but not much more useful since currently
user couldn't do anything in-UI to fix the situation. Implementation
is based on the one in knotty.
Fixes [YOCTO #9288]
Signed-off-by: Jussi Kukkonen <jussi.kukkonen at intel.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>
---
lib/bb/ui/depexp.py | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
diff --git a/lib/bb/ui/depexp.py b/lib/bb/ui/depexp.py
index 995703d..d879e04 100644
--- a/lib/bb/ui/depexp.py
+++ b/lib/bb/ui/depexp.py
@@ -301,6 +301,30 @@ def main(server, eventHandler, params):
if isinstance(event, bb.command.CommandCompleted):
continue
+ if isinstance(event, bb.event.NoProvider):
+ if event._runtime:
+ r = "R"
+ else:
+ r = ""
+
+ extra = ''
+ if not event._reasons:
+ if event._close_matches:
+ extra = ". Close matches:\n %s" % '\n '.join(event._close_matches)
+
+ if event._dependees:
+ print("Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)%s" % r, event._item, ", ".join(event._dependees), r, extra)
+ else:
+ print("Nothing %sPROVIDES '%s'%s" % (r, event._item, extra))
+ if event._reasons:
+ for reason in event._reasons:
+ print(reason)
+
+ _, error = server.runCommand(["stateShutdown"])
+ if error:
+ print('Unable to cleanly shutdown: %s' % error)
+ break
+
if isinstance(event, bb.command.CommandFailed):
print("Command execution failed: %s" % event.error)
return event.exitcode
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Openembedded-commits
mailing list