From: Zac Medico Date: Fri, 21 May 2010 00:09:06 +0000 (-0700) Subject: Make the non --update package selection logic avoid installed packages if X-Git-Tag: v2.2_rc68~590 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=445181a538b65ac3d3a1d5560448b166ff9495ea;p=portage.git Make the non --update package selection logic avoid installed packages if they are masked. Thanks to Daniel Robbins for reporting. --- diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index c102a7a2d..d7f42c916 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -2719,7 +2719,11 @@ class depgraph(object): return pkg, existing_node bestmatch = portage.best( - [pkg.cpv for pkg in matched_packages]) + [pkg.cpv for pkg in matched_packages if pkg.visible]) + if not bestmatch: + # all are masked, so ignore visibility + bestmatch = portage.best( + [pkg.cpv for pkg in matched_packages]) matched_packages = [pkg for pkg in matched_packages \ if portage.dep.cpvequal(pkg.cpv, bestmatch)]