i feel like i submitted this before ... root@vapier 0 glibc # portageq has_version / glibc Traceback (most recent call last): File "/usr/bin/portageq", line 295, in ? main() File "/usr/bin/portageq", line 290, in main function(sys.argv[2:]) File "/usr/bin/portageq", line 43, in has_version mylist=portage.db[argv[0]]["vartree"].dbapi.match(argv[1]) File "/usr/lib/portage/pym/portage.py", line 4518, in match mydep = dep_expand( File "/usr/lib/portage/pym/portage.py", line 3429, in dep_expand return prefix + cpv_expand( File "/usr/lib/portage/pym/portage.py", line 3623, in cpv_expand raise ValueError, matches ValueError: ['sys-libs/glibc', 'cross-mips64el-unknown-linux-gnu/glibc', 'cross-armeb-unknown-linux-gnu/glibc', 'cross-sh4-unknown-linux-gnu/glibc', 'cross-arm-unknown-linux-gnu/glibc'] Portage 2.1.1_pre2-r2 (default-linux/amd64/2006.0, gcc-4.1.1, glibc-2.4-r3, 2.6.16.20-grsec x86_64) ================================================================= System uname: 2.6.16.20-grsec x86_64 AMD Athlon(tm) 64 Processor 3500+ Gentoo Base System version 1.6.15 distcc 2.18.3 x86_64-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] ccache version 2.4 [enabled] dev-lang/python: 2.4.3-r1 dev-python/pycrypto: 2.0.1-r5 dev-util/ccache: 2.4-r2 dev-util/confcache: [Not Present] sys-apps/sandbox: 1.2.18.1 sys-devel/autoconf: 2.13, 2.60 sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2 sys-devel/binutils: 2.15.92.0.2-r10, 2.16-r1, 2.16.1, 2.16.1-r3, 2.16.90.0.3, 2.16.91.0.1, 2.16.91.0.2, 2.16.91.0.3, 2.16.91.0.4, 2.16.91.0.5, 2.16.91.0.6, 2.16.91.0.7, 2.16.92, 2.16.93, 2.16.94, 2.17, 2.17.50.0.2 sys-devel/gcc-config: 1.3.13-r2 sys-devel/libtool: 1.5.22 virtual/os-headers: 2.6.17 ACCEPT_KEYWORDS="amd64 ~amd64" AUTOCLEAN="yes" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -march=k8 -pipe -Wimplicit-function-declaration" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config /var/qmail/alias /var/qmail/control /var/vpopmail/domains /var/vpopmail/etc" CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c" CXXFLAGS="-O2 -march=k8 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="assume-digests autoconfig ccache cvs distlocks metadata-transfer noinfo sandbox sfperms sign splitdebug" GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo" INSTALL_MASK="/usr/share/applications /usr/kde/*/share/applications /lib/udev/devices" LANG="en" LC_ALL="en_US" LDFLAGS="-Wl,-O1 -Wl,-z,relro" LINGUAS="de en es cs" MAKEOPTS="-j6" PKGDIR="/usr/portage/packages" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/gentoo-x86" SYNC="rsync://gentoo/gentoo-portage" USE="amd64 X a52 aac aalib acl adns aio alsa asf audiofile berkdb bitmap-fonts bzip2 cairo cddb cdparanoia cli crypt cups curl dba directfb divx4linux dlloader dri dts dvd dvdr dvdread emboss encode exif fbcon ffmpeg flac flash foomaticdb ftp gd gif glitz glut gphoto2 gpm gtk gtk2 imap imlib ipv6 isdnlog jbig joystick jpeg jpeg2k libcaca libedit lzo lzw lzw-tiff mad maildir matroska mikmod mime mng modplug mp3 mpeg mplayer multislot ncurses nls nptl nptlonly nvidia offensive ogg oggvorbis openal opengl pcre pdf pdflib perl pic png pppd python qt3 qt4 quicktime readline reflection samba sdl session sndfile spell spl ssl subtitles svg tcltk tcpd tga theora threads tiff truetype truetype-fonts type1-fonts usb vcd vorbis wmf xanim xine xinerama xml xml2 xmms xorg xpm xrandr xv xvid xvmc zlib elibc_glibc input_devices_mouse input_devices_keyboard input_devices_joystick input_devices_void kernel_linux linguas_de linguas_en linguas_es linguas_cs userland_GNU video_cards_nvidia video_cards_nv video_cards_ati video_cards_r128 video_cards_radeon video_cards_vga video_cards_sisusb" Unset: CTARGET, EMERGE_DEFAULT_OPTS, PORTAGE_RSYNC_EXTRA_OPTS
(In reply to comment #0) > i feel like i submitted this before ... That's because cpv_expand() is called from lots of places and the ValueError needs to be caught and handled correctly for each of those places. It's been caught in a few places, but there are still a few left...
This is fixed (works with Portage 2.1.2-r11).
Still looks broken to me: $ portageq has_version / gcc Traceback (most recent call last): File "/usr/bin/portageq", line 346, in ? main() File "/usr/bin/portageq", line 341, in main function(sys.argv[2:]) File "/usr/bin/portageq", line 56, in has_version mylist=portage.db[argv[0]]["vartree"].dbapi.match(argv[1]) File "/usr/lib/portage/pym/portage.py", line 5205, in match mydep = dep_expand( File "/usr/lib/portage/pym/portage.py", line 4276, in dep_expand return prefix + cpv_expand( File "/usr/lib/portage/pym/portage.py", line 4492, in cpv_expand raise ValueError, matches ValueError: ['sys-devel/gcc', 'cross-mingw32/gcc']
Oh yeah, it looks like it fails only if you have more packages with same $PN. Didn't know that, sorry.
This is fixed in 2.2 at least.