My portage-version is sys-apps/portage-2.0.51-r10. appro / # emerge portage Calculating dependencies ...done! >>> emerge (1 of 1) sys-apps/portage-2.0.51-r10 to / Traceback (most recent call last): File "/usr/bin/emerge", line 3036, in ? mydepgraph.merge(mydepgraph.altlist()) File "/usr/bin/emerge", line 1837, in merge retval=portage.doebuild(y,"merge",myroot,self.pkgsettings,edebug) File "/usr/lib/portage/pym/portage.py", line 2570, in doebuild if not fetch(fetchme, mysettings, listonly=listonly, fetchonly=fetchonly): File "/usr/lib/portage/pym/portage.py", line 1678, in fetch filedict[myfile].insert(primaryuri_index, myuri) NameError: global name 'primaryuri_index' is not defined Looks like there was something missed during the recent changes. In /usr/lib/portage/pym/portage.py line 1678 filedict[myfile].insert(primaryuri_index, myuri) should be filedict[myfile].insert(primaryuri_indexes[myfile], myuri) .. I guess. I made it a blocker because I can't downgrade portage as a workaround. Reproducible: Always Steps to Reproduce: 1. 2. 3. Portage 2.0.51-r10 (default-linux/x86/2004.3, gcc-3.4.3, glibc-2.3.4.20041102-r0, 2.6.9-gentoo-r13 i686) ================================================================= System uname: 2.6.9-gentoo-r13 i686 AMD Athlon(tm) XP 2600+ Gentoo Base System version 1.4.16 Python: dev-lang/python-2.3.4 [2.3.4 (#1, Oct 17 2004, 04:40:08)] distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled] dev-lang/python: 2.3.4 sys-devel/autoconf: 2.59-r5 sys-devel/automake: 1.8.5-r1 sys-devel/binutils: 2.15.90.0.1.1-r3 sys-devel/libtool: 1.5.2-r7 virtual/os-headers: 2.6.8.1-r2 ACCEPT_KEYWORDS="x86" AUTOCLEAN="yes" CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer -mfpmath=sse -fforce-addr -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -maccumulate-outgoing-args -ffast-math -fprefetch-loop-arrays" CHOST="i686-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control" CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d" CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer -mfpmath=sse -fforce-addr -frerun-cse-after-loop -frerun-loop-opt -falign-functions=4 -maccumulate-outgoing-args -ffast-math -fprefetch-loop-arrays" DISTDIR="/usr/local/portage/distfiles" FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms userpriv" GENTOO_MIRRORS="http://mirrors.sec.informatik.tu-darmstadt.de/gentoo ftp://linux.rz.ruhr-uni-bochum.de/gentoo-mirror http://www.ibiblio.org/pub/Linux/distributions/gentoo " MAKEOPTS="-j5" PKGDIR="/usr/local/portage/packages" PORTAGE_TMPDIR="/var/tmp" PORTDIR="/usr/portage" PORTDIR_OVERLAY="/usr/local/portage/bmg-gnome-current /usr/local/portage/bmg-main /usr/local/portage/gentoo-de /usr/local/portage/deltup /usr/local/portage/local" SYNC="rsync://rsync.de.gentoo.org/gentoo-portage" USE="3dnow X alsa apm attr avi bash-completion bitmap-fonts cdr chroot crypt cups directfb divx4linux doc encode f77 fbcon flac foomaticdb fortran gd gdbm gtk gtk2 guile hyriand imagemagick imap imlib ithreads java jpeg libg++ libwww mad matroska mbox mikmod mmx motif mpeg ncurses nfs nntp nptl nptlonly offensive oggvorbis opengl oss pam pdflib perl png python quicktime readline reiserfs samba sasl sdl slang spell sse ssl svga tcpd threads tiff truetype userlocales x86 xml xml2 xmms xv xvid zlib" Unset: LDFLAGS
The ebuild will be adjust shortly to allow you to update/change versions.
Fixed and released in -r11 and -r12
I avoided this problem with putting line "=sys-apps/portage-2.0.51-r15" in package.mask and then updating portage to portage-2.0.51-r14. After that I did emerge sync (but commenting previous added line in package.mask would be enough) and then update of portage was successful.
Workaround proposed in Comment #3 did the work for me.
Even more simple it is to do it directly, without modifying any files: # emerge "=sys-apps/portage-2.0.51-r14"
*** Bug 83104 has been marked as a duplicate of this bug. ***
#3 and #5 would work if I still had portage-2.0.51-r14 around. However in the current portage tree there is -r15, and .18 and .19. Neither one I can emerge. Thus I am currently stuck on several machines with an old emerge and I cannot update quite a lot of things because of this. Any other fix?
Remove "primaryuri" from RESTRICT within the ebuild.
Wow...quick, easy, and works. Thanks!
Fixed on or before 2.0.51.22-r1
Looking through the batch of bugs, I'm not sure that some of these are actually fixed in stable. Others, the requirements have possibly changed after the initial fix was committed. If you think this bug has been closed incorrectly, please reopen or ask that it be reopened.