From 50524c152cf374573feb2b63e656efe9758a7d4f Mon Sep 17 00:00:00 2001 From: Robert Yang Date: Tue, 18 Feb 2020 18:48:02 +0800 Subject: bitbake: event: Remove duplicated items from close matches It printed duplicated ones when there are multiple similar recipes in differrent layers, for example, if python-lockfile in different layers, and there is no python3-lockfile: $ bitbake python3-lockfile ERROR: Nothing PROVIDES 'python3-lockfile'. Close matches: python-lockfile python-lockfile python3-aiofiles Remove the duplicated ones to fix the problem. (Bitbake rev: 5612192cec9f467e2ab5a86482cb34876d198bc6) Signed-off-by: Robert Yang Signed-off-by: Richard Purdie --- bitbake/lib/bb/event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bitbake') diff --git a/bitbake/lib/bb/event.py b/bitbake/lib/bb/event.py index 5cfbf36126..d1359f0100 100644 --- a/bitbake/lib/bb/event.py +++ b/bitbake/lib/bb/event.py @@ -508,7 +508,7 @@ class NoProvider(Event): extra = '' if not self._reasons: if self._close_matches: - extra = ". Close matches:\n %s" % '\n '.join(self._close_matches) + extra = ". Close matches:\n %s" % '\n '.join(sorted(set(self._close_matches))) if self._dependees: msg = "Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)%s" % (r, self._item, ", ".join(self._dependees), r, extra) -- cgit v1.2.3-54-g00ecf