Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 472298 - emerge fails with --keep-going when a REQUIRED_USE constraint is unsatisfied
Summary: emerge fails with --keep-going when a REQUIRED_USE constraint is unsatisfied
Status: RESOLVED DUPLICATE of bug 328343
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Dependencies (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-04 15:36 UTC by Martin Mokrejš
Modified: 2013-06-04 23:41 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Mokrejš 2013-06-04 15:36:12 UTC
I think in some bug report I already asked that 'revdep-rebuild -i' should invoke 'emerge --keep-going'. Here I see a broken behavior of python-updater:

# python-updater
 * Starting Python Updater...
 * Main active version of Python:    2.7
 * Active version of Python 2:       2.7
 * Active version of Python 3:       3.2
 * Globally supported Python ABIs in installed repositories:
 *   gentoo:                         2.4 2.5 2.6 2.7 3.1 3.2 3.3 2.5-jython 2.7-jython 2.7-pypy-1.7 2.7-pypy-1.8 2.7-pypy-1.9 2.7-pypy-2.0
 *   science:                        2.4 2.5 2.6 2.7 3.1 3.2 3.3 2.5-jython 2.7-jython 2.7-pypy-1.7 2.7-pypy-1.8 2.7-pypy-1.9 2.7-pypy-2.0
 *   x-layman:                       2.4 2.5 2.6 2.7 3.1 3.2 3.3 2.5-jython 2.7-jython 2.7-pypy-1.7 2.7-pypy-1.8 2.7-pypy-1.9 2.7-pypy-2.0
 *   x-portage:                      2.4 2.5 2.6 2.7 3.1 3.2 3.3 2.5-jython 2.7-jython 2.7-pypy-1.7 2.7-pypy-1.8 2.7-pypy-1.9 2.7-pypy-2.0
 *   Adding to list: app-portage/gentoolkit:0
 *   Adding to list: dev-python/argparse:0
 *   Adding to list: dev-python/beautifulsoup:python-3
 *   Adding to list: dev-python/bsddb3:0
 *   Adding to list: dev-python/dbus-python:0
 *   Adding to list: dev-python/elementtree:0
 *   Adding to list: dev-python/imaging:0
 *   Adding to list: dev-python/lxml:0
 *   Adding to list: dev-python/matplotlib:0
 *   Adding to list: dev-python/mysql-python:0
 *   Adding to list: dev-python/pycairo:0
 *   Adding to list: dev-python/pycxx:0
 *   Adding to list: dev-python/pygobject:2
 *   Adding to list: dev-python/pygtk:2
 *   Adding to list: dev-python/pyrex:0
 *   Adding to list: dev-python/pysqlite:2
 *   Adding to list: dev-python/pytz:0
 *   Adding to list: dev-python/pyxml:0
 * emerge -Dv1 --keep-going app-portage/gentoolkit:0 dev-python/argparse:0 dev-python/beautifulsoup:python-3 dev-python/bsddb3:0 dev-python/dbus-python:0 dev-python/elementtree:0 dev-python/imaging:0 dev-python/lxml:0 dev-python/matplotlib:0 dev-python/mysql-python:0 dev-python/pycairo:0 dev-python/pycxx:0 dev-python/pygobject:2 dev-python/pygtk:2 dev-python/pyrex:0 dev-python/pysqlite:2 dev-python/pytz:0 dev-python/pyxml:0

 * IMPORTANT: 18 news items need reading for repository 'gentoo'.
 * Use eselect news to read news items.


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

Calculating dependencies /

!!! Problem resolving dependencies for dev-python/argparse:0
... done!

!!! The ebuild selected to satisfy "dev-python/argparse:0" has unmet requirements.
- dev-python/argparse-1.2.1-r2::gentoo USE="" PYTHON_TARGETS="-python2_5 -python2_6 -python3_1"

  The following REQUIRED_USE flag constraints are unsatisfied:
    any-of ( python_targets_python2_5 python_targets_python2_6 python_targets_python3_1 )

#

# emerge --info
Portage 2.1.11.62 (default/linux/amd64/13.0, gcc-4.6.3, glibc-2.17, 2.6.35.9-default x86_64)
=================================================================
System uname: Linux-2.6.35.9-default-x86_64-Intel-R-_Core-TM-2_Quad_CPU_Q9650_@_3.00GHz-with-gentoo-2.2
KiB Mem:    16446524 total,    109252 free
KiB Swap:   15647296 total,  15447148 free
Timestamp of tree: Sun, 02 Jun 2013 20:30:01 +0000
ld GNU ld (GNU Binutils) 2.23.1
distcc 3.1 x86_64-pc-linux-gnu [disabled]
app-shells/bash:          4.2_p45
dev-java/java-config:     2.2.0
dev-lang/python:          2.5.4-r5, 2.6.8-r1, 2.7.3-r3, 3.1.5-r1, 3.2.3-r2
dev-util/cmake:           2.8.10.2-r2
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.6-r1
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.4_p6-r1, 1.5-r1, 1.9.6-r3, 1.10.3, 1.11.6, 1.12.6, 1.13.1
sys-devel/binutils:       2.23.1
sys-devel/gcc:            4.3.5, 4.4.7, 4.5.4, 4.6.3, 4.7.2-r1
sys-devel/gcc-config:     1.8
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.8 (virtual/os-headers)
sys-libs/glibc:           2.17
Repositories: gentoo science x-portage x-layman
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA dlj-1.1 sun-bcla-java-vm Oracle-BCLA-JavaSE"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=nocona"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/openvpn/easy-rsa /usr/share/polkit-1/actions /var/bind /var/lib/hsqldb /var/spool/torque"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.4/ext-active/ /etc/php/cgi-php5.4/ext-active/ /etc/php/cli-php5.4/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe -march=nocona"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news nostrip parallel-fetch protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j5"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/science /usr/local/portage /var/lib/layman"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X accessibility alsa amd64 amr apache apache2 berkdb bzip2 cairo cgi cli cracklib crypt cups cxx dbus device-mapper dri encode ffmpeg flac fontconfig fortran gd gdbm gnutls hal iconv id3tag innodb java jce jpeg jpg kde ladspa laptop mad maildir mmx modules mpi mpich2 multilib mysql ncurses nfs nls nptl nptlonly nsplugin ogg opengl openmp openssl pam pcre perl php png policykit postfix procmail python qt3support qt4 readline sasl server session sndfile sse sse2 ssl suexec svg syslog tcpd threads tiff truetype unicode usb wavpack xml xorg zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en cs cz" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby19 ruby18" USERLAND="GNU" VIDEO_CARDS="vesa" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

#

So, as usually, will do now:

for p in app-portage/gentoolkit:0 dev-python/argparse:0 dev-python/beautifulsoup:python-3 dev-python/bsddb3:0 dev-python/dbus-python:0 dev-python/elementtree:0 dev-python/imaging:0 dev-python/lxml:0 dev-python/matplotlib:0 dev-python/mysql-python:0 dev-python/pycairo:0 dev-python/pycxx:0 dev-python/pygobject:2 dev-python/pygtk:2 dev-python/pyrex:0 dev-python/pysqlite:2 dev-python/pytz:0 dev-python/pyxml:0; do emerge -Dv1 --keep-going  $p; done
Comment 1 Mike Gilbert gentoo-dev 2013-06-04 15:45:21 UTC
This is really not specific to python-updater; it would happen any time you start a merge with an unsatisfied REQUIRED_USE constraint.

I think the current behavior is reasonable, but I can see the other side of it as well.
Comment 2 Zac Medico gentoo-dev 2013-06-04 21:39:01 UTC
What you really want is a combination of bug 403207 and bug 258371, so that emerge will automatically satisfy REQUIRED_USE. It is beyond the scope of --keep-going.

*** This bug has been marked as a duplicate of bug 258371 ***
Comment 3 Martin Mokrejš 2013-06-04 21:59:10 UTC
I don't think this is enough for me. If for whatever reason a child emerge dies then the process of reinstalls to be done by revdep-rebuild will just stop the iteration.

I really want revdep-rebuild to continue, like I get with the simple shell loop which effectively ignores that some of the children failed.

This is even more helpful because emerge often fails to resolve ordering of packages so it is anyway just a random ordering. And therefore, this stupid shell loop is just the right thing to do to get at least some broken fixed. In the attempt to run 'revdep-rebuild -i' one will get less pakages and maybe will get all fixed. Why do we have to wait for a magic, sophisticated fix? Please make a workaround until a proper fix (bug #403207 and bug #258371) exists. Ideally REOPEN the bug as I don't think this has to be marked as a duplicate. Anyway, thanks for your time.
Comment 4 Zac Medico gentoo-dev 2013-06-04 22:06:55 UTC
(In reply to Martin Mokrejš from comment #3)
> Please make a workaround until a proper fix (bug #403207 and bug
> #258371) exists. 

I'm not sure what you're suggesting. Do you want emerge to ignore REQUIRED_USE, skip packages with unsatisfied REQUIRED_USE, or are you suggesting a change to python-updater?
Comment 5 Martin Mokrejš 2013-06-04 22:52:41 UTC
[I have reworked my comment hopefully to make it clearer.]

I don't think this is enough for me. If for whatever reason a child emerge process forked by python-updater dies then revdep-rebuild does not continue the list of packages to be reinstalled.

I really want revdep-rebuild to continue, like I get with the simple shell loop which effectively ignores that some of the children failed.

This is even more helpful because emerge (or revdep-rebuild?) often fails to resolve ordering of packages so it is anyway just a random ordering of packages in a row. And therefore, this stupid shell loop is just the right thing to do to get at least some broken packages reinstalled. In a subsequent attempt to run 'revdep-rebuild -i' one will get less pakages and maybe will get through at the second pass. Why do we have to wait for a magic, sophisticated fix? Please make a workaround so that *revdep-rebuild calls emerge child processes in a loop* until a proper fix (bug #403207 and bug #258371) exists. In other words, ignore the exitcode of children. Ideally REOPEN the bug as I don't think this has to be marked as a duplicate. Anyway, thanks for your time.
Comment 6 Martin Mokrejš 2013-06-04 22:54:59 UTC
(In reply to Zac Medico from comment #4)
> (In reply to Martin Mokrejš from comment #3)
> > Please make a workaround until a proper fix (bug #403207 and bug
> > #258371) exists. 
> 
> I'm not sure what you're suggesting. Do you want emerge to ignore
> REQUIRED_USE, skip packages with unsatisfied REQUIRED_USE, or are you
> suggesting a change to python-updater?

In brief, while not knowing what I am really talking about, the 2) or 3) sounds like what I probably want (in terms of functionality).
Comment 7 Zac Medico gentoo-dev 2013-06-04 23:41:50 UTC
Skipping packages with unsatisfied REQUIRED_USE fits bug 328343. Once that's fixed, python-updater will be able to make use of it.

*** This bug has been marked as a duplicate of bug 328343 ***