From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 6D9681380DC for ; Wed, 5 Feb 2014 19:42:14 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 8C507E0BB9; Wed, 5 Feb 2014 19:42:13 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 08C18E0C11 for ; Wed, 5 Feb 2014 19:42:12 +0000 (UTC) Received: from spoonbill.gentoo.org (spoonbill.gentoo.org [81.93.255.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id B7DBB33F94F for ; Wed, 5 Feb 2014 19:42:11 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by spoonbill.gentoo.org (Postfix) with ESMTP id 8B57E18878 for ; Wed, 5 Feb 2014 19:42:09 +0000 (UTC) From: "Sebastian Luther" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Sebastian Luther" Message-ID: <1391629161.ae2103b5d8936b105edf2e5fba4c9b191f74415b.few@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/_emerge/ X-VCS-Repository: proj/portage X-VCS-Files: pym/_emerge/depgraph.py X-VCS-Directories: pym/_emerge/ X-VCS-Committer: few X-VCS-Committer-Name: Sebastian Luther X-VCS-Revision: ae2103b5d8936b105edf2e5fba4c9b191f74415b X-VCS-Branch: master Date: Wed, 5 Feb 2014 19:42:09 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 3230b3c5-051b-4fc3-ac7e-d234d2f991c7 X-Archives-Hash: 57b07dc7236f9ea513c4bf112dcf2b01 commit: ae2103b5d8936b105edf2e5fba4c9b191f74415b Author: Sebastian Luther gmx de> AuthorDate: Fri Jan 24 09:06:21 2014 +0000 Commit: Sebastian Luther gmx de > CommitDate: Wed Feb 5 19:39:21 2014 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=ae2103b5 Replace _slot_collision_nodes with _package_tracker --- pym/_emerge/depgraph.py | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 484ac14..1bb086b 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -378,9 +378,6 @@ class _dynamic_depgraph_config(object): # This use used to check if we have accounted for blockers # relevant to a package. self._traversed_pkg_deps = set() - # Slot collision nodes are not allowed to block other packages since - # blocker validation is only able to account for one package per slot. - self._slot_collision_nodes = set() self._parent_atoms = {} self._slot_conflict_handler = None self._circular_dependency_handler = None @@ -1799,11 +1796,16 @@ class depgraph(object): buildpkgonly = "--buildpkgonly" in self._frozen_config.myopts nodeps = "--nodeps" in self._frozen_config.myopts if dep.blocker: + + # Slot collision nodes are not allowed to block other packages since + # blocker validation is only able to account for one package per slot. + is_slot_conflict_parent = any(dep.parent in conflict.pkgs[1:] for conflict in \ + self._dynamic_config._package_tracker.slot_conflicts()) if not buildpkgonly and \ not nodeps and \ not dep.collapsed_priority.ignored and \ not dep.collapsed_priority.optional and \ - dep.parent not in self._dynamic_config._slot_collision_nodes: + not is_slot_conflict_parent: if dep.parent.onlydeps: # It's safe to ignore blockers if the # parent is an --onlydeps node. @@ -2019,7 +2021,6 @@ class depgraph(object): level=logging.DEBUG, noiselevel=-1) else: - self._add_slot_conflict(pkg) if debug: writemsg_level( "%s%s %s\n" % ("Slot Conflict:".ljust(15), @@ -2138,9 +2139,6 @@ class depgraph(object): self._dynamic_config._slot_operator_deps[slot_key] = slot_info slot_info.append(dep) - def _add_slot_conflict(self, pkg): - self._dynamic_config._slot_collision_nodes.add(pkg) - def _add_pkg_deps(self, pkg, allow_unsatisfied=False): myroot = pkg.root @@ -6019,7 +6017,7 @@ class depgraph(object): if "complete" not in self._dynamic_config.myparams and \ self._dynamic_config._allow_backtracking and \ - self._dynamic_config._slot_collision_nodes and \ + any(self._dynamic_config._package_tracker.slot_conflicts()) and \ not self._accept_blocker_conflicts(): self._dynamic_config.myparams["complete"] = True