Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 233973

Summary: app-portage/gentoolkit should depend on dev-lang/python[xml]
Product: Gentoo Linux Reporter: Lizel <lizel>
Component: Current packagesAssignee: Portage Tools Team <tools-portage>
Status: RESOLVED FIXED    
Severity: normal CC: chris, me, mephinet, mike.gualtieri, python, radek, uhlar, wschlich
Priority: High    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---

Description Lizel 2008-08-05 12:42:38 UTC
ran "glsa-check -l"
[A] means this GLSA was already applied,
[U] means the system is not affected and
[N] indicates that the system might be affected.

Traceback (most recent call last):
  File "/usr/bin/glsa-check", line 206, in <module>
    sys.exit(summarylist(glsalist))
  File "/usr/bin/glsa-check", line 172, in summarylist
    myglsa = Glsa(myid, glsaconfig)
  File "/usr/lib/gentoolkit/pym/glsa.py", line 414, in __init__
    self.read()
  File "/usr/lib/gentoolkit/pym/glsa.py", line 432, in read
    self.parse(urllib.urlopen(myurl))
  File "/usr/lib/gentoolkit/pym/glsa.py", line 446, in parse
    self.DOM = xml.dom.minidom.parse(myfile)
  File "/usr/lib/python2.5/xml/dom/minidom.py", line 1912, in parse
    from xml.dom import expatbuilder
  File "/usr/lib/python2.5/xml/dom/expatbuilder.py", line 32, in <module>
    from xml.parsers import expat
  File "/usr/lib/python2.5/xml/parsers/expat.py", line 4, in <module>
    from pyexpat import *


Since upgrading python from 2.4 to 2.5 I cannot do a glsa-check. I have checked if expat is installed and it is.

Reproducible: Always

Steps to Reproduce:
1.Upgrade python from 2.4 to 2.5
2.revdep-rebuild -X
3.glsa-check -l


Actual Results:  
I get an ImportError: No module named pyexpat, I have checked if expat is installed and it is.

Expected Results:  
List Glsa's
Comment 1 Lizel 2008-08-05 12:43:10 UTC
emerge --info
Portage 2.1.4.4 (default/linux/x86/2008.0, gcc-4.1.2, glibc-2.4-r3, 2.6.22-gentoo-r2 i686)
=================================================================
System uname: 2.6.22-gentoo-r2 i686 Intel(R) Pentium(R) D CPU 3.00GHz
Timestamp of tree: Mon, 04 Aug 2008 20:04:01 +0000
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.4.4-r13, 2.5.2-r6
dev-python/pycrypto: 2.0.1-r6
sys-apps/baselayout: 1.12.4-r7
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.61-r2
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -pipe -march=pentium3 -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php4/ext-active/ /etc/php/apache2-php5/ext-active/ /e
hp4/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php4/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/w
CXXFLAGS="-O2 -pipe -march=pentium3 -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="distlocks metadata-transfer parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
GENTOO_MIRRORS="http://ftp.belnet.be/mirror/rsync.gentoo.org/gentoo/ http://gentoo.mirrors.tds.net/gentoo/"
LDFLAGS="-Wl,-O1"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles
local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/portage/local"
SYNC="rsync://rsync.belnet.be/gentoo-portage"
USE="acl apache2 berkdb bzip2 cli cracklib crypt doc dri exiscan-acl fam fortran gdbm iconv ipv6 isdnlog java jikes libg++ mailwrapper midi mmx mudflap 
nptl nptlonly openmp pam pcre perl postgres pppd python readline reflection session spell spl sse ssl sysfs tcpd threads unicode x86 xorg zlib" ALSA_CAR
als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-a
 via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_
ulti null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_d
ault authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filt
nclude info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc
CES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" USERLAND="GNU" VIDEO_CARDS
t i810 mach64 mga neomagic nv r128 radeon savage sis tdfx trident vesa vga via vmware voodoo"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS

Comment 2 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2008-08-05 19:30:07 UTC
(mass-change) Please do not use the Bugzilla product for system issues. Per the large red text it is only for problems with the Gentoo bugs.gentoo.org site only.
Comment 3 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2008-08-05 19:39:04 UTC
*** Bug 233971 has been marked as a duplicate of this bug. ***
Comment 4 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2008-08-05 19:41:48 UTC
You need to run python-updater after upgrading python. As evident from the ewarn message that the ebuild spits out:

 * If you have just upgraded from an older version of python you will
 * need to run:
 * /usr/sbin/python-updater
 * This will automatically rebuild all the python dependent modules
 * to run with python-2.5.
 * Your original Python is still installed and can be accessed via
 * /usr/bin/python2.x.

Please re-open if this doesn't solve it.
Comment 5 Lizel 2008-08-06 05:58:09 UTC
Hi Jeremy, thanks for your reply.

I have run python updater and this was the output.


 * Starting Python Updater from 2.4 to 2.5 :
 * No packages needs to be remerged.
Comment 6 Jeroen Roovers (RETIRED) gentoo-dev 2008-08-07 01:49:58 UTC
Which version of app-portage/gentoolkit do you actually use?
Comment 7 Lizel 2008-08-07 06:13:16 UTC
(In reply to comment #6)
> Which version of app-portage/gentoolkit do you actually use?
> 

gentoolkit-0.2.3-r1
Comment 8 Chris Paulson-Ellis 2008-08-07 06:45:22 UTC
I am also getting this (with the same Traceback) after updating python to 2.5.

When doing the update I merged python-2.5, did python-update -i, removed python 2.4 and did a revdep-rebuild -X.

After seeing the problem, I updated gentoolkit (to 0.2.3-r1), but it is still broken.

Regards,
Chris.
Comment 9 Chris Paulson-Ellis 2008-08-07 07:06:49 UTC
The problem can be fixed by manually merging dev-python/pyxml. I presume this is a dependency of gentoolkit that was previously part of (or a dependency of) python-2.4.

Regards,
Chris.
Comment 10 Chris Paulson-Ellis 2008-08-07 07:14:34 UTC
Another data-point...

I have a machine with gentoolkit-0.2.4_rc3 (rather than the more usual 0.2.3-r1). This machine does not have pyxml installed after the python-2.5 update, but does *not* have the problem with glsa-check.

So presumably, another fix is to update to the unstable gentoolkit.

Chris.
Comment 11 Lizel 2008-08-07 07:18:56 UTC
You are brilliant, it worked. 
emerge pyxml
dispatch-conf
and I can do glsa-check again.

Thank you so much for all your help.
Comment 12 Chris Paulson-Ellis 2008-08-07 07:25:19 UTC
Strangely, I have yet more machines that have the stable gentoolkit and no pyxml for which this is *not* a problem after updating to python-2.5. Figure that one out!
Comment 13 Lizel 2008-08-07 07:29:50 UTC
You are brilliant, it worked. 
emerge pyxml
dispatch-conf
and I can do glsa-check again.

Thank you so much for all your help.
Comment 14 Radek Podgorny 2008-12-09 10:18:54 UTC
I don't think this is actually fixed. I've found myself in the same situation (but with gajim missing pyexpat). Merging pyxml is a solution but it should be pulled in by some depend.
Comment 15 Matus UHLAR - fantomas 2008-12-15 12:46:34 UTC
it's the missing /usr/lib64/python2.5/lib-dynload/pyexpat.so library, which is available in python-2.5.2-r6, but not in the python-2.5.2-r7
Comment 16 Paul Varner (RETIRED) gentoo-dev 2008-12-15 15:11:08 UTC
python herd:
I have tried reproducing this error several times on my machines and have been unable to do so.  Any suggestions on what is wrong?
Comment 17 Matus UHLAR - fantomas 2008-12-15 15:20:40 UTC
(In reply to comment #16)
> python herd:
> I have tried reproducing this error several times on my machines and have been
> unable to do so.  Any suggestions on what is wrong?
> 

which version of python do you have installed? Do you have pyexpat installed?
2.5.2-r6 isn't in portage anymore, 2.5.2-r8 seems to include expat and pyexpat by default


Comment 18 Matus UHLAR - fantomas 2008-12-15 15:33:46 UTC
funny, after rebuilding of python it started to work...
Comment 19 Jesus Rivero (RETIRED) gentoo-dev 2008-12-16 03:22:46 UTC
Hello, 

    Please, could people having this issue with pyexpat show their output of:

    $ equery uses dev-lang/python

 Thanks, 
Comment 20 Matus UHLAR - fantomas 2008-12-16 12:31:17 UTC
[ Searching for packages matching dev-lang/python... ]
[ Colour Code : set unset ]
[ Legend : Left column  (U) - USE flags from make.conf              ]
[        : Right column (I) - USE flags packages was installed with ]
[ Found these USE variables for dev-lang/python-2.5.2-r7 ]
 U I
 + + berkdb       : Adds support for sys-libs/db (Berkeley DB for MySQL)
 - - build        : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping [make stage1]
 - - doc          : Adds extra documentation (API, Javadoc, etc)
 - - elibc_uclibc : <unknown>
 - - examples     : Install examples, usually source code
 + + gdbm         : Adds support for sys-libs/gdbm (GNU database libraries)
 - - ipv6         : Adds support for IP version 6
 + + ncurses      : Adds ncurses support (console display library)
 + + readline     : Enables support for libreadline, a GNU line-editing library that almost everyone wants
 - - sqlite       : Adds support for sqlite - embedded sql database
 + + ssl          : Adds support for Secure Socket Layer connections
 - + threads      : Adds threads support for various packages. Usually pthreads
 - - tk           : Adds support for Tk GUI toolkit
 - - ucs2         : Enable byte size 2 unicode (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 - - wininst      : Install required Windows executables to create an executable installer for MS Windows.


on another marhine where I already re-compiled the same version python, it's the same, but the /usr/lib64/python2.5/lib-dynload/pyexpat.so is available.
Comment 21 Vladimir 2009-01-06 13:34:15 UTC
(In reply to comment #19)
> Hello, 
> 
>     Please, could people having this issue with pyexpat show their output of:
> 
>     $ equery uses dev-lang/python
> 
>  Thanks, 
> 

# equery uses dev-lang/python
[ Searching for packages matching dev-lang/python... ]
[ Colour Code : set unset ]
[ Legend : Left column  (U) - USE flags from make.conf              ]
[        : Right column (I) - USE flags packages was installed with ]
[ Found these USE variables for dev-lang/python-2.4.4-r6 ]
 U I
 + + berkdb       : Adds support for sys-libs/db (Berkeley DB for MySQL)
 - - bootstrap    : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used during original system bootstrapping [make stage2]
 - - build        : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping [make stage1]
 - + doc          : Adds extra documentation (API, Javadoc, etc)
 - - elibc_uclibc : <unknown>
 - - examples     : Install examples, usually source code
 - - gdbm         : Adds support for sys-libs/gdbm (GNU database libraries)
 - - ipv6         : Adds support for IP version 6
 + + ncurses      : Adds ncurses support (console display library)
 - - nocxx        : Disable support for C++ (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 - - nothreads    : Disable threads (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 + + readline     : Enables support for libreadline, a GNU line-editing library that almost everyone wants
 + + ssl          : Adds support for Secure Socket Layer connections
 - - tk           : Adds support for Tk GUI toolkit
 - - ucs2         : Enable byte size 2 unicode (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
[ Found these USE variables for dev-lang/python-2.5.2-r7 ]
 U I
 + + berkdb       : Adds support for sys-libs/db (Berkeley DB for MySQL)
 - - build        : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping [make stage1]
 - + doc          : Adds extra documentation (API, Javadoc, etc)
 - - elibc_uclibc : <unknown>
 - - examples     : Install examples, usually source code
 - - gdbm         : Adds support for sys-libs/gdbm (GNU database libraries)
 - - ipv6         : Adds support for IP version 6
 + + ncurses      : Adds ncurses support (console display library)
 + + readline     : Enables support for libreadline, a GNU line-editing library that almost everyone wants
 - - sqlite       : Adds support for sqlite - embedded sql database
 + + ssl          : Adds support for Secure Socket Layer connections
 - + threads      : Adds threads support for various packages. Usually pthreads
 - - tk           : Adds support for Tk GUI toolkit
 - - ucs2         : Enable byte size 2 unicode (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 - - wininst      : Install required Windows executables to create an executable installer for MS Windows.
Comment 22 rhatto 2009-01-15 13:01:49 UTC
[ Searching for packages matching dev-lang/python... ]
[ Colour Code : set unset ]
[ Legend : Left column  (U) - USE flags from make.conf              ]
[        : Right column (I) - USE flags packages was installed with ]
[ Found these USE variables for dev-lang/python-2.4.4-r9 ]
 U I
 + + berkdb       : Adds support for sys-libs/db (Berkeley DB for MySQL)
 - - bootstrap    : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used during original system bootstrapping [make stage2]
 - - build        : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping [make stage1]
 - - doc          : Adds extra documentation (API, Javadoc, etc)
 - - elibc_uclibc : <unknown>
 - - examples     : Install examples, usually source code
 + - gdbm         : Adds support for sys-libs/gdbm (GNU database libraries)
 + + ipv6         : Adds support for IP version 6
 + + ncurses      : Adds ncurses support (console display library)
 - - nocxx        : Disable support for C++ (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 - - nothreads    : Disable threads (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 + + readline     : Enables support for libreadline, a GNU line-editing library that almost everyone wants
 + + ssl          : Adds support for Secure Socket Layer connections
 - - tk           : Adds support for Tk GUI toolkit
 - - ucs2         : Enable byte size 2 unicode (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
[ Found these USE variables for dev-lang/python-2.5.2-r7 ]
 U I
 + + berkdb       : Adds support for sys-libs/db (Berkeley DB for MySQL)
 - - bootstrap    : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used during original system bootstrapping [make stage2]
 - - build        : !!internal use only!! DO NOT SET THIS FLAG YOURSELF!, used for creating build images and the first half of bootstrapping [make stage1]
 - - doc          : Adds extra documentation (API, Javadoc, etc)
 - - elibc_uclibc : <unknown>
 - - examples     : Install examples, usually source code
 + + gdbm         : Adds support for sys-libs/gdbm (GNU database libraries)
 + + ipv6         : Adds support for IP version 6
 + + ncurses      : Adds ncurses support (console display library)
 + + readline     : Enables support for libreadline, a GNU line-editing library that almost everyone wants
 - - sqlite       : Adds support for sqlite - embedded sql database
 + + ssl          : Adds support for Secure Socket Layer connections
 - + threads      : Adds threads support for various packages. Usually pthreads
 - - tk           : Adds support for Tk GUI toolkit
 - - ucs2         : Enable byte size 2 unicode (DON'T USE THIS UNLESS YOU KNOW WHAT YOU'RE DOING)
 - - wininst      : Install required Windows executables to create an executable installer for MS Windows.
Comment 23 Benny Pedersen 2009-02-14 03:52:09 UTC
python 2.5.2-r7 just need xml use flag to fix this bug here

USE="-xml" emerge python
glsa-check -t all

shows the bug

USE="xml" emerge python
glsa-check -t all

works here then
Comment 24 mephinet 2009-03-11 21:02:26 UTC
(In reply to comment #23)
> python 2.5.2-r7 just need xml use flag to fix this bug here

Reproducible, adding the XML use flag for python plus reemerging python solves the issue.

So the ebuild should be modified as follows, I guess:

EAPI="2"
DEPEND=">=dev-lang/python-2.0[xml]"
Comment 25 Matus UHLAR - fantomas 2009-03-16 11:06:01 UTC
this apparently requires expat2, with expat1 it's broken. Can this be the problem?
Comment 26 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2009-03-20 23:26:57 UTC
*** Bug 263056 has been marked as a duplicate of this bug. ***
Comment 27 Paul Varner (RETIRED) gentoo-dev 2009-08-28 18:03:48 UTC
I'm pretty confident this is bug 281968

*** This bug has been marked as a duplicate of bug 281968 ***
Comment 28 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2009-08-28 18:59:37 UTC
(In reply to comment #27)
> I'm pretty confident this is bug 281968

No. glsa-check still won't work when dev-lang/python has been built with USE="-xml".
Comment 29 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2009-08-28 19:13:32 UTC
Maintainers:
Can I fix this bug?
Comment 30 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2009-08-28 20:22:59 UTC
This bug was fixed some time ago.