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 78958138010 for ; Fri, 26 Oct 2012 06:06:46 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id E497C21C06B; Fri, 26 Oct 2012 06:06:35 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 66A2E21C06B for ; Fri, 26 Oct 2012 06:06:35 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 994CE335DF3 for ; Fri, 26 Oct 2012 06:06:34 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 38002E5436 for ; Fri, 26 Oct 2012 06:06:32 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1351231577.cbe52a133e4480cefd22ca51dd0c133c09eb93f4.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: pym/portage/tests/resolver/, pym/_emerge/ X-VCS-Repository: proj/portage X-VCS-Files: pym/_emerge/depgraph.py pym/portage/tests/resolver/test_slot_operator_unsatisfied.py X-VCS-Directories: pym/portage/tests/resolver/ pym/_emerge/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: cbe52a133e4480cefd22ca51dd0c133c09eb93f4 X-VCS-Branch: master Date: Fri, 26 Oct 2012 06:06:32 +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: 8cce22cc-33f9-4570-9a58-5b5b065008e4 X-Archives-Hash: 831b4c3c0f882b39102d13e041c5325a commit: cbe52a133e4480cefd22ca51dd0c133c09eb93f4 Author: Zac Medico gentoo org> AuthorDate: Fri Oct 26 06:06:17 2012 +0000 Commit: Zac Medico gentoo org> CommitDate: Fri Oct 26 06:06:17 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=cbe52a13 depgraph: trigger rebuild for unbuilt child This will fix bug #439694, where built slot-operator deps failed to trigger rebuilds if the deps were initially broken. --- pym/_emerge/depgraph.py | 4 ++-- .../resolver/test_slot_operator_unsatisfied.py | 7 +++++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py index 41bdc8e..e129a81 100644 --- a/pym/_emerge/depgraph.py +++ b/pym/_emerge/depgraph.py @@ -1192,7 +1192,7 @@ class depgraph(object): for slot_key, slot_info in self._dynamic_config._slot_operator_deps.items(): for dep in slot_info: - if not (dep.child.built and dep.parent and + if not (dep.parent and isinstance(dep.parent, Package) and dep.parent.built): continue @@ -1619,7 +1619,7 @@ class depgraph(object): not (deep is not True and depth > deep)) dep.child = pkg - if (not pkg.onlydeps and pkg.built and + if (not pkg.onlydeps and dep.atom and dep.atom.slot_operator_built): self._add_slot_operator_dep(dep) diff --git a/pym/portage/tests/resolver/test_slot_operator_unsatisfied.py b/pym/portage/tests/resolver/test_slot_operator_unsatisfied.py index 14631eb..e3b53d1 100644 --- a/pym/portage/tests/resolver/test_slot_operator_unsatisfied.py +++ b/pym/portage/tests/resolver/test_slot_operator_unsatisfied.py @@ -43,13 +43,16 @@ class SlotOperatorUnsatisfiedTestCase(TestCase): test_cases = ( # Demonstrate bug #439694, where a broken slot-operator - # sub-slot dependency fails to trigger rebuild. + # sub-slot dependency needs to trigger a rebuild. ResolverPlaygroundTestCase( ["@world"], options = {"--update": True, "--deep": True}, success = True, - mergelist = ["app-misc/A-1"]), + mergelist = ["app-misc/B-0"]), + # This doesn't trigger a rebuild, since there's no version + # change to trigger complete graph mode, and initially + # unsatisfied deps are ignored in complete graph mode anyway. ResolverPlaygroundTestCase( ["app-misc/A"], options = {"--oneshot": True},