commit: 70704ab3f8983dd69a4742cd4c3a0810e4eed7e5
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Mon Jan 4 20:51:39 2016 +0000
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Tue May 10 17:53:45 2016 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=70704ab3
repoman: filter out duplicate dependencies in error messages
Some packages list the same atom multiple times (e.g. behind diff USE
flags). If one of them throws an error, we end up listing it more than
once, and the output can get verbose/useless.
pym/repoman/modules/scan/depend/profile.py | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/pym/repoman/modules/scan/depend/profile.py
b/pym/repoman/modules/scan/depend/profile.py
index 5b32f66..a714a93 100644
--- a/pym/repoman/modules/scan/depend/profile.py
+++ b/pym/repoman/modules/scan/depend/profile.py
@@ -201,13 +201,22 @@ class ProfileDependsChecks(ScanBase):
# we have some
unsolvable deps
# remove ! deps, which
always show up as unsatisfiable
- atoms = [
+ all_atoms = [
str(atom.unevaluated_atom)
for atom in
atoms if not atom.blocker]
# if we emptied out our
list, continue:
- if not atoms:
+ if not all_atoms:
continue
+
+ # Filter out
duplicates. We do this by hand (rather
+ # than use a set) so
the order is stable and better
+ # matches the order
that's in the ebuild itself.
+ atoms = []
+ for atom in all_atoms:
+ if atom not in
atoms:
+
atoms.append(atom)
+
if
self.options.output_style in ['column']:
self.qatracker.add_error(mykey,
"%s:
%s: %s(%s) %s"