> Were you getting this issue with xml.dom showing on first request all
> the time, or only occasionally occurring? If the latter, were you
> running things in a multithreaded configuration and was the server
> being loaded with lots of concurrent requests?

It was the former.

> For your particular Python installation, does the '_xmlplus' module
> exist? Ie., can you import it as '_xmlplus' or 'xml.doc._xmlplus'?

No, it appears I don't have _xmlplus; neither 'import _xmlplus' nor
'import xml.doc._xmlplus' works.

My python installation is the default which came with debian 5.0
(i.e., I didn't build it from source with unorthodox configuration
options, or use apt).

As a final note, I wound up switching to cElementTree for parsing the
xml (not only for performance but also because the code is much more
concise), and I found that I don't need a full package path with that
module.

I.e, the import statement is:

from cElementTree import ElementTree, Element, SubElement, iterparse,
tostring, fromstring

and within each function I can simply refer to Element, SubElement,
etc. w/o the full path prefix.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to