* [gentoo-commits] proj/portage:master commit in: lib/_emerge/, lib/portage/dbapi/
@ 2020-02-01 21:32 Zac Medico
0 siblings, 0 replies; only message in thread
From: Zac Medico @ 2020-02-01 21:32 UTC (permalink / raw
To: gentoo-commits
commit: 44076b9432a1361a39515927de2b60baa2fbddb9
Author: Zac Medico <zmedico <AT> gentoo <DOT> org>
AuthorDate: Sat Feb 1 21:23:39 2020 +0000
Commit: Zac Medico <zmedico <AT> gentoo <DOT> org>
CommitDate: Sat Feb 1 21:30:23 2020 +0000
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=44076b94
cpv_expand: treat GLEP 81 acct-* categories like virtual (bug 691798)
This solves common name collisions introduced by GLEP 81 user and group
management packages.
TODO: Provide user configuration so that users an ignore name
collisions with selected categories like app-emacs or dev-haskell.
Signed-off-by: Zac Medico <zmedico <AT> gentoo.org>
lib/_emerge/depgraph.py | 2 +-
lib/portage/dbapi/cpv_expand.py | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/lib/_emerge/depgraph.py b/lib/_emerge/depgraph.py
index cae1c4470..1eaf20035 100644
--- a/lib/_emerge/depgraph.py
+++ b/lib/_emerge/depgraph.py
@@ -4212,7 +4212,7 @@ class depgraph(object):
if len(expanded_atoms) > 1:
number_of_virtuals = 0
for expanded_atom in expanded_atoms:
- if expanded_atom.cp.startswith("virtual/"):
+ if expanded_atom.cp.startswith(("acct-group/", "acct-user/", "virtual/")):
number_of_virtuals += 1
else:
candidate = expanded_atom
diff --git a/lib/portage/dbapi/cpv_expand.py b/lib/portage/dbapi/cpv_expand.py
index 70ee78245..ac2f6cc2e 100644
--- a/lib/portage/dbapi/cpv_expand.py
+++ b/lib/portage/dbapi/cpv_expand.py
@@ -72,9 +72,9 @@ def cpv_expand(mycpv, mydb=None, use_cache=1, settings=None):
matches.append(x+"/"+myp)
if len(matches) > 1:
virtual_name_collision = False
- if len(matches) == 2:
+ if len(matches) > 1:
for x in matches:
- if not x.startswith("virtual/"):
+ if not x.startswith(("acct-group/", "acct-user/", "virtual/")):
# Assume that the non-virtual is desired. This helps
# avoid the ValueError for invalid deps that come from
# installed packages (during reverse blocker detection,
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-02-01 21:32 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-01 21:32 [gentoo-commits] proj/portage:master commit in: lib/_emerge/, lib/portage/dbapi/ Zac Medico
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox