Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 290818 - [PATCH] portage could resolve blocker and slot conflicts better by upgrading also packages that are not in depgraph
Summary: [PATCH] portage could resolve blocker and slot conflicts better by upgrading ...
Status: IN_PROGRESS
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Dependencies (show other bugs)
Hardware: All Linux
: High normal with 1 vote (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
: 299833 379509 417165 424391 493096 540398 556168 558936 (view as bug list)
Depends on:
Blocks: 155723 300071
  Show dependency tree
 
Reported: 2009-10-27 22:56 UTC by Vlastimil Babka (Caster) (RETIRED)
Modified: 2016-02-21 19:48 UTC (History)
13 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
backtrack to force update of blocked packages (blocker-backtracking-to-force-updates.patch,3.67 KB, patch)
2012-05-17 23:22 UTC, Zac Medico
Details | Diff
backtrack to force update of blocked packages (blocker-backtracking-to-force-updates.patch,4.67 KB, patch)
2012-06-23 04:39 UTC, Zac Medico
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2009-10-27 22:56:46 UTC
example: emerge -uvaDN xorg-server (want to do this before the rest of the world) fails because some of the updates have blocks on older versions of xinerama and xscreensaver that are installed. However these blocking packages are not pulled to be updated (not in xorg-server depgraph), so emerge fails. Adding them manually to the emerge command next to xorg-server makes it work. This could be automatic.
Comment 1 Vlastimil Babka (Caster) (RETIRED) gentoo-dev 2009-11-25 15:28:44 UTC
Hm didn't check if --complete-graph=y makes any difference in the current portage. Assuming not.
But maybe it would make sense to use this option in this case, if its slowing the resolution down?
Comment 2 Zac Medico gentoo-dev 2009-11-25 20:56:07 UTC
(In reply to comment #1)
> Hm didn't check if --complete-graph=y makes any difference in the current
> portage. Assuming not.

Right, it makes no difference atm. Unsolved blockers simply cause it to bail out in any case. What we want to do is use the existing backtracking framework to create a logical package mask (masking the installed version of xorg-server, for example) and then restart the dependency calculation. We may also be able to use a lookahead mechanism in order to avoid the need for backtracking in some obvious cases.

> But maybe it would make sense to use this option in this case, if its slowing
> the resolution down?

We might as well enable it in this case since it's safer and it probably won't add much time to the calculation, if any.
Comment 3 Zac Medico gentoo-dev 2010-01-06 16:24:36 UTC
*** Bug 299833 has been marked as a duplicate of this bug. ***
Comment 4 Doktor Notor 2010-03-19 12:11:28 UTC
Hmmm, I don't really get this behaviour...

$ emerge -pv =media-libs/gstreamer-0.10.28 =media-libs/gst-plugins-base-0.10.28

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U ] media-libs/gstreamer-0.10.28 [0.10.25] USE="nls -test" 3,092 kB
[ebuild     U ] media-libs/gst-plugins-base-0.10.28 [0.10.25] USE="-debug nls" 2,289 kB
[blocks b     ] <media-libs/gst-plugins-base-0.10.26 ("<media-libs/gst-plugins-base-0.10.26" is blocking media-libs/gstreamer-0.10.28)

Notably, I don't get any upgrade because of this "blocker" when running emerge -uD world so unless I resolve this manually I'll probably be stuck with outdated versions of the above forever.

--complete-graph makes no difference and that I don't get at all, there's tons of stuff installed here that depends on media-libs/gst-plugins-base and media-libs/gstreamer here. What's up here?
Comment 5 Doktor Notor 2010-03-19 12:20:28 UTC
# emerge -u -D 3 -av world

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild     U ] media-libs/gstreamer-0.10.28 [0.10.25] USE="nls -test" 3,092 kB [0]
[ebuild     U ] media-libs/gst-plugins-base-0.10.28 [0.10.25] USE="-debug nls" 2,289 kB [0]
[ebuild     U ] www-client/chromium-5.0.342.5 [5.0.307.11] USE="-bindist% ffmpeg plugins-symlink" 0 kB [0=>1]
[blocks B     ] <media-libs/gst-plugins-base-0.10.26 ("<media-libs/gst-plugins-base-0.10.26" is blocking media-libs/gstreamer-0.10.28)

Total: 3 packages (3 upgrades), Size of downloads: 5,381 kB
Conflict: 1 block (1 unsatisfied)
Portage tree and overlays:
 [0] /usr/portage
 [1] /usr/local/portage

 * Error: The above package list contains packages which cannot be
 * installed at the same time on the same system.

  ('installed', '/', 'media-libs/gst-plugins-base-0.10.25', 'nomerge') pulled in by
    =media-libs/gst-plugins-base-0.10* required by ('installed', '/', 'media-plugins/gst-plugins-taglib-0.10.17', 'nomerge')
    >=media-libs/gst-plugins-base-0.10.20 required by ('installed', '/', 'app-cdr/xfburn-0.4.3', 'nomerge')
    >=media-libs/gst-plugins-base-0.10 required by ('installed', '/', 'net-wireless/bluez-4.62', 'nomerge')
    (and 42 more)

  ('ebuild', '/', 'media-libs/gstreamer-0.10.28', 'merge') pulled in by
    >=media-libs/gstreamer-0.10.15 required by ('installed', '/', 'app-cdr/brasero-2.28.3', 'nomerge')
    >=media-libs/gstreamer-0.10.25 required by ('installed', '/', 'media-plugins/gst-plugins-lame-0.10.13', 'nomerge')
    =media-libs/gstreamer-0.10* required by ('installed', '/', 'media-plugins/gst-plugins-meta-0.10-r4', 'nomerge')
    (and 23 more)

Eh... ???
Comment 6 Zac Medico gentoo-dev 2010-03-19 22:15:29 UTC
(In reply to comment #5)
That seems like a slightly different issue. Can you please file a new bug and post output for `emerge -puD --debug --backtrack=0 world` (and emerge --info as usual)?
Comment 7 Sebastian Luther (few) 2010-06-30 17:12:26 UTC
A patch can be found here:

http://github.com/few/fews-portage-branch/tree/update_if_needed
Comment 8 Zac Medico gentoo-dev 2011-03-18 19:00:28 UTC
(In reply to comment #7)
> A patch can be found here:
> 
> http://github.com/few/fews-portage-branch/tree/update_if_needed

Backtracking is one way to do it. I've also had a suggestion from davidjames@google to translate < blockers into pseudo-dependencies that pull in updates. Using this approach, we may be able to avoid triggering backtracking in the first place, so it would be more efficient.
Comment 9 Dave Kemper 2011-08-21 01:03:34 UTC
*** Bug 379509 has been marked as a duplicate of this bug. ***
Comment 10 Zac Medico gentoo-dev 2012-05-17 23:22:17 UTC
Created attachment 312147 [details, diff]
backtrack to force update of blocked packages

(In reply to comment #7)
> A patch can be found here:
> 
> http://github.com/few/fews-portage-branch/tree/update_if_needed

Here's a rebase of that patch on current master.
Comment 11 Zac Medico gentoo-dev 2012-05-22 20:33:38 UTC
*** Bug 417165 has been marked as a duplicate of this bug. ***
Comment 12 Zac Medico gentoo-dev 2012-06-23 04:39:09 UTC
Created attachment 316015 [details, diff]
backtrack to force update of blocked packages

Here's a rebase of the patch, with a failing test case that seems like we should be able to handle if we tweak the logic a little.
Comment 13 Zac Medico gentoo-dev 2012-07-01 19:34:00 UTC
*** Bug 424391 has been marked as a duplicate of this bug. ***
Comment 14 Zac Medico gentoo-dev 2014-12-01 15:45:55 UTC
*** Bug 493096 has been marked as a duplicate of this bug. ***
Comment 15 Zac Medico gentoo-dev 2015-02-17 19:43:45 UTC
*** Bug 540398 has been marked as a duplicate of this bug. ***
Comment 16 Zac Medico gentoo-dev 2015-03-14 17:32:59 UTC
*** Bug 543290 has been marked as a duplicate of this bug. ***
Comment 17 Zac Medico gentoo-dev 2015-10-12 17:03:08 UTC
*** Bug 558936 has been marked as a duplicate of this bug. ***
Comment 18 Zac Medico gentoo-dev 2016-02-21 19:48:42 UTC
*** Bug 556168 has been marked as a duplicate of this bug. ***