Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 384644 Details for
Bug 522652
Rebuild not triggered with RDEPEND="|| ( other_package some_package:= )" and --dynamic-deps=n
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
dep_zapdeps: fix bug #522652
dep_zapdeps-fix-bug-522652.patch (text/plain), 3.51 KB, created by
Zac Medico
on 2014-09-13 02:46:47 UTC
(
hide
)
Description:
dep_zapdeps: fix bug #522652
Filename:
MIME Type:
Creator:
Zac Medico
Created:
2014-09-13 02:46:47 UTC
Size:
3.51 KB
patch
obsolete
>From c3d375e89978d702f96c05c7b10b29657b31f74b Mon Sep 17 00:00:00 2001 >From: Zac Medico <zmedico@gentoo.org> >Date: Fri, 12 Sep 2014 17:32:53 -0700 >Subject: [PATCH 1/2] dep_zapdeps: fix bug #522652 > >For cases such as || ( X <A-2 ), where X is unsatisfiable and A-1 is >installed, fix dep_zapdeps to make the correct choice. >--- > pym/portage/dep/dep_check.py | 10 ++++ > pym/portage/tests/resolver/test_or_choices.py | 73 +++++++++++++++++++++++++++ > 2 files changed, 83 insertions(+) > >diff --git a/pym/portage/dep/dep_check.py b/pym/portage/dep/dep_check.py >index 22eed96..4386b5e 100644 >--- a/pym/portage/dep/dep_check.py >+++ b/pym/portage/dep/dep_check.py >@@ -287,6 +287,7 @@ def dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None): > unsat_use_non_installed = [] > other_installed = [] > other_installed_some = [] >+ other_installed_any_slot = [] > other = [] > > # unsat_use_* must come after preferred_non_installed >@@ -301,6 +302,7 @@ def dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None): > unsat_use_non_installed, > other_installed, > other_installed_some, >+ other_installed_any_slot, > other, > ) > >@@ -504,6 +506,14 @@ def dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None): > other_installed.append(this_choice) > elif some_installed: > other_installed_some.append(this_choice) >+ >+ # Use Atom(atom.cp) for a somewhat "fuzzy" match, since >+ # the whole atom may be too specific. For example, see >+ # bug #522652, where using the whole atom leads to an >+ # unsatisfiable choice. >+ elif any(vardb.match(Atom(atom.cp)) for atom in atoms >+ if not atom.blocker): >+ other_installed_any_slot.append(this_choice) > else: > other.append(this_choice) > >diff --git a/pym/portage/tests/resolver/test_or_choices.py b/pym/portage/tests/resolver/test_or_choices.py >index 90e6814..d9d14f0 100644 >--- a/pym/portage/tests/resolver/test_or_choices.py >+++ b/pym/portage/tests/resolver/test_or_choices.py >@@ -132,3 +132,76 @@ class OrChoicesTestCase(TestCase): > self.assertEqual(test_case.test_success, True, test_case.fail_msg) > finally: > playground.cleanup() >+ >+ >+ def testInitiallyUnsatisfied(self): >+ >+ ebuilds = { >+ >+ "app-misc/A-1" : { >+ "EAPI": "5", >+ "SLOT": "0/1" >+ }, >+ >+ "app-misc/A-2" : { >+ "EAPI": "5", >+ "SLOT": "0/2" >+ }, >+ >+ "app-misc/B-0" : { >+ "EAPI": "5", >+ "RDEPEND": "app-misc/A:=" >+ }, >+ >+ "app-misc/C-0" : { >+ "EAPI": "5", >+ "RDEPEND": "|| ( app-misc/X <app-misc/A-2 )" >+ }, >+ >+ } >+ >+ installed = { >+ >+ "app-misc/A-1" : { >+ "EAPI": "5", >+ "SLOT": "0/1" >+ }, >+ >+ "app-misc/B-0" : { >+ "EAPI": "5", >+ "RDEPEND": "app-misc/A:0/1=" >+ }, >+ >+ "app-misc/C-0" : { >+ "EAPI": "5", >+ "RDEPEND": "|| ( app-misc/X <app-misc/A-2 )" >+ }, >+ >+ } >+ >+ world = ["app-misc/B", "app-misc/C"] >+ >+ test_cases = ( >+ >+ # Test bug #522652, where the unsatisfiable app-misc/X >+ # atom is selected, and the dependency is placed into >+ # _initially_unsatisfied_deps where it is ignored, causing >+ # upgrade to app-misc/A-2 (breaking a dependency of >+ # app-misc/C-0). >+ ResolverPlaygroundTestCase( >+ ["app-misc/A"], >+ options = {}, >+ success = True, >+ mergelist = ['app-misc/A-1'] >+ ), >+ >+ ) >+ >+ playground = ResolverPlayground(ebuilds=ebuilds, >+ installed=installed, world=world, debug=False) >+ try: >+ for test_case in test_cases: >+ playground.run_TestCase(test_case) >+ self.assertEqual(test_case.test_success, True, test_case.fail_msg) >+ finally: >+ playground.cleanup() >-- >1.8.5.5 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 522652
: 384644