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

Bug 367753

Summary: dev-python/zsi: Prepare to use xml.use_pyxml()
Product: Gentoo Linux Reporter: Arfrever Frehtes Taifersar Arahesis (RETIRED) <arfrever>
Component: Current packagesAssignee: Christoph Mende (RETIRED) <angelos>
Status: RESOLVED FIXED    
Severity: normal CC: python
Priority: High    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 367951    
Bug Blocks: 367729    

Description Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2011-05-17 17:18:36 UTC
This package specifies dependency on dev-python/pyxml.

Please test this package with dev-lang/python-2.7.1-r2:2.7 or >=dev-lang/python-2.7.2_pre20110515:2.7, which require explicit calling of xml.use_pyxml() before using PyXML.

If this package actually needs PyXML, then modify all modules/scripts of this package, which import xml module. The following code should be added before first import of anything from xml module:

import xml
if hasattr(xml, "use_pyxml"):
    xml.use_pyxml()

This code works with previous versions of Python, so no changes in dependencies are needed.
Comment 1 Christoph Mende (RETIRED) gentoo-dev 2011-05-18 19:27:35 UTC
./ZSI/wstools/Utility.py:import xml.dom.minidom
the only match, also seems to work fine with python-2.7.1-r2
Comment 2 Arfrever Frehtes Taifersar Arahesis (RETIRED) gentoo-dev 2011-05-18 19:42:35 UTC
Use:
grep -Er '(import.*xml|xml.*import)' .

CHANGES of dev-python/zsi-2.1_alpha1 contains:
"Change for 2.1.0_a1 released 31-Oct-2007:
    -   No PyXML Dependency, use minidom by default (much faster)"

If dev-python/zsi-2.1_alpha1 doesn't need dev-python/pyxml, then dev-python/pyxml should be removed from dependencies of dev-python/zsi-2.1_alpha1.
Comment 3 Christoph Mende (RETIRED) gentoo-dev 2011-07-09 22:12:22 UTC
2.1 deps fixed and 2.0 removed