From 3faeebbed6a3613d501c6892e3b6b03d9779fd22 Mon Sep 17 00:00:00 2001 From: Zac Medico Date: Sun, 4 Dec 2011 15:43:36 -0800 Subject: depgraph: fix case insensitive search for unsat This fixes an interaction between the code from commits 9ce6da43ab90c4dab97ebf3b8339e5dbc113a0a8 and cbe44d92ff13b8a22f5b4215b73078ce600c6bf4, so that we don't discard matches that are identical except for differnces in upper/lower case. --- pym/_emerge/depgraph.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 3bda89442..57619e098 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -3296,9 +3296,17 @@ class depgraph(object): for other_cp in list(all_cp): other_pkg = portage.catsplit(other_cp)[1] if other_pkg == pkg: - # discard dir containing no ebuilds - all_cp.discard(other_cp) - continue + # Check for non-identical package that + # differs only by upper/lower case. + identical = True + for cp_orig in orig_cp_map[other_cp]: + if cp_orig != cp: + identical = False + break + if identical: + # discard dir containing no ebuilds + all_cp.discard(other_cp) + continue pkg_to_cp.setdefault(other_pkg, set()).add(other_cp) pkg_matches = difflib.get_close_matches(pkg, pkg_to_cp) matches = [] -- cgit v1.2.3-1-g7c22