XML Parser Trouble in Python 2.1
deblNospammmy at theworld.com
Tue May 29 21:01:57 EDT 2001
Yup, when I try your import I get:
Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "/usr/local/python21/lib/python2.1/xml/parsers/expat.py", line 4,
from pyexpat import *
ImportError: libexpat.so.0: cannot open shared object file: No such file
Can someone tell me where I get the missing library(s) from?
Paul Prescod wrote:
> David Lees wrote:
> > However, when I try executing it on my RedHat Linux 7.1 system I get the
> > following error stack, which puzzles me. I do not understand why some
> > of the error messages even refer to 'sax' parser, since I am using dom.
> > And I am puzzled why I get any errors in the first place.
> I have a feeling you are missing the expat library. Try this:
> >>> import xml.parsers.expat
> >>> parser = xml.parsers.expat.ParserCreate()
> Take a recipe. Leave a recipe.
> Python Cookbook! http://www.ActiveState.com/pythoncookbook
More information about the Python-list