Have I broken my installation?

Andreas Jung lists at andreas-jung.com
Sat Jun 28 15:40:12 EDT 2003


I think you should have installed a recent version of Expat.

-aj

--On Samstag, 28. Juni 2003 16:23 Uhr +0100 Matt Mower 
<mmower at novissio.com> wrote:

> Hi folks,
>
> I have an old Linux box that I am messing about with Python on.  The
> RedHat installed version is 1.5 something so I have built & installed
> 2.2.2 in /opt/python.
>
> I've started trying to play with XML and ran into an error when
> attempting to parse a document:
>
>> Traceback (most recent call last):
>>  File "/mnt/hugedisk/share/MattsMovableType/stb/stb.cgi", line 90, in ?
>>    documentElem = parse( rssFile )
>>  File "/opt/python/lib/python2.2/xml/dom/minidom.py", line 962, in parse
>>    return _doparse(pulldom.parse, args, kwargs)
>>  File "/opt/python/lib/python2.2/xml/dom/minidom.py", line 953, in
>>  _doparse events = apply(func, args, kwargs)
>>  File "/opt/python/lib/python2.2/xml/dom/pulldom.py", line 328, in parse
>>    parser = xml.sax.make_parser()
>>  File "/opt/python/lib/python2.2/xml/sax/__init__.py", line 93, in
>>  make_parser raise SAXReaderNotAvailable("No parsers found", None)
>> xml.sax._exceptions.SAXReaderNotAvailable: No parsers found
>
> Googling around it seems like I needed to build XML support when I
> built Python.  I'm not sure what I should have done differently when I
> built in order to make that happen.  The other option on offer
> appeared to be installing PyXML.
>
> I duly downloaded PyXML 0.8.2 and installed it (again into /opt/python
> using --prefix).
>
> Now instead of the previous error I get a different problem entirely:
>
>> Traceback (most recent call last):
>>  File "/mnt/hugedisk/share/MattsMovableType/stb/stb.cgi", line 18, in ?
>>    from xml.dom.minidom import parse, Document
>>  File "./xml.py", line 2, in ?
>>    from xml.dom.minidom import parse
>> ImportError: No module named dom.minidom
>
> I'm pretty sure I had a module dom.minidom before as it is the import
> statement that is raising the exception and it didn't prior to
> installing PyXML, I was previously calling parse() and Document().
>
> So did I make a mistake installing PyXML?  Can anyone advise me on
> what my next steps should be?
>
> Many thanks,
>
> Matt
>
> ---
> Systems Engineer, Hipbone(EMEA) Ltd.
> 3000 Hillswood drive, Chertsey, Surrey, KT16 0RS
> Tel: 44-1932-895902  Mob: 44-7980-237-380
> --
> http://mail.python.org/mailman/listinfo/python-list









More information about the Python-list mailing list