Summary: | Any of many dependency in ebuild with use flags solved wrong ( pkg not installed || pkg installed with a specific use flag ) | ||
---|---|---|---|
Product: | Portage Development | Reporter: | Jan Buecken <jb.faq> |
Component: | Enhancement/Feature Requests | Assignee: | Portage team <dev-portage> |
Status: | CONFIRMED --- | ||
Severity: | normal | CC: | esigra, tsmksubc |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | All | ||
URL: | https://devmanual.gentoo.org/general-concepts/dependencies/index.html | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 155723 | ||
Attachments: | unit test |
Description
Jan Buecken
2018-02-17 11:22:02 UTC
There have been a number of recent changes in the relevant code, so you may get a different result with the portage-2.3.24 (see bug 645002). The reason it chooses the blocker is that this choice "costs less" because it doesn't have to install media-plugins/alsa-plugins[abi_x86_32(-)], but the cost calculation has changed in portage-2.3.24, so what portage version are you using? Also, the way that you are using the blocker looks questionable, but it might work as intended with portage-2.3.24. (In reply to Zac Medico from comment #1) > There have been a number of recent changes in the relevant code, so you may > get a different result with the portage-2.3.24 (see bug 645002). Same result > > The reason it chooses the blocker is that this choice "costs less" because > it doesn't have to install media-plugins/alsa-plugins[abi_x86_32(-)] But it chooses it even if media-plugins/alsa-plugins[abi_x86_32(-)] is fullfilled already, is this as intended? > but > the cost calculation has changed in portage-2.3.24, so what portage version > are you using? Tested with 2.3.19-r1 (~)2.3.24-r > > Also, the way that you are using the blocker looks questionable, but it > might work as intended with portage-2.3.24. I did not found any documentation to do what I want to do. Is there a best practise guide? (maybe I need to switch to gentoo forum with this question, but at least this bug should sort out if portage works as intended in this case and/or if https://devmanual.gentoo.org/general-concepts/dependencies/index.html needs a update?) Greetings Created attachment 521060 [details] unit test The attached unit test reproduces the problem. This patch suppresses the problem: > diff --git a/pym/portage/dep/dep_check.py b/pym/portage/dep/dep_check.py > index 2896e2389..b4614be0c 100644 > --- a/pym/portage/dep/dep_check.py > +++ b/pym/portage/dep/dep_check.py > @@ -562,10 +562,10 @@ def dep_zapdeps(unreduced, reduced, myroot, use_binaries=0, trees=None, > # added to the digraph, in order to distinguish between > # those packages and installed packages that may need > # to be uninstalled in order to resolve blockers. > - if not any(pkg in graph for pkg in > - graph_db.match_pkgs(atom)): > - all_in_graph = False > - break > + #if not any(pkg in graph for pkg in > + # graph_db.match_pkgs(atom)): > + # all_in_graph = False > + # break > circular_atom = None > if not (parent is None or priority is None) and \ > (parent.onlydeps or Generally, blockers are used to indicate a conflict of some kind, and the presence of some package (such as media-plugins/alsa-plugins) typically does not make this sort of conflict "disappear". |