[Distutils] Craziness in dependency checking of PyXML version
Stanley A. Klein
sklein at cpcug.org
Tue Jan 15 03:03:35 CET 2008
I created the ZSI rpm myself using python setup.py bdist_rpm.
The PyXML rpm on my Fedora system was created by Fedora. I will have to
create one myself for Centos.
BTW, as I said in an earlier email, I found an easier fix. I commented
out the statement in the ZSI setup.py that caused Python to check for the
dependency.
Stan Klein
On Mon, January 14, 2008 7:50 pm, Phillip J. Eby wrote:
> At 06:56 PM 1/14/2008 -0500, Stanley A. Klein wrote:
>>I'm trying to fix something running under ZSI that broke because of a
>>needed change in the WS-Addressing schema version.
>>
>>I ran into a problem that I've had before, where Python can't recognize
>>that I have a proper version of PyXML installed.
>>
>>I get the following traceback:
>>
>>[stan at localhost wsdl]$ wsdl2py -help
>>Traceback (most recent call last):
>> File "/usr/bin/wsdl2py", line 5, in <module>
>> from pkg_resources import load_entry_point
>> File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 2561,
>> in
>><module>
>> working_set.require(__requires__)
>> File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 626, in
>>require
>> needed = self.resolve(parse_requirements(requirements))
>> File "/usr/lib/python2.5/site-packages/pkg_resources.py", line 524, in
>>resolve
>> raise DistributionNotFound(req) # XXX put more info here
>>pkg_resources.DistributionNotFound: PyXML>=0.8.3
>>
>>What I have installed as an rpm is PyXML-0.8.4-6.
>>
>>I've had this problem before with the PyXML version in another context,
>>probably trying to install ZSI as an egg in my user lib directory.
>>
>>Is there an easy fix for this?
>
> Yes: convince the organization that creates your RPMs not to remove
> the .egg-info files that the distutils generates, specifically so
> that system-installed packages can be detected programmatically,
> without needing to understand every single distribution format in
> existence.
>
> Or, failing that, create an empty "PyXML-0.8.4-py2.5.egg-info" file
> alongside the top-level modules or packages that were installed by the
> RPM. :)
>
--
More information about the Distutils-SIG
mailing list