xml.minidom and threads

Andrew Clover and-google at doxdesk.com
Mon Mar 15 04:03:13 EST 2004


Sunil Movva <sunilmovva at hotmail.com> wrote:

> So, I came to suspect if xml.minidom module is thread-safe. 

No it isn't, but I doubt this is your problem as you don't seem to be
trying to access the DOM Nodes from multiple threads, let alone
concurrently. (Is there any good reason why you need to serialise and
re-parse between each thread?)

A SAXParseException is generally what it says on the tin, caused by
faulty syntax in the XML document being parsed. It is conceivable that
minidom's serialisation code at the second-thread-output stage is
producing something wrong; we'd have to have a look at the string the
third thread is trying to parse to find out what.

-- 
Andrew Clover
mailto:and at doxdesk.com
http://www.doxdesk.com/



More information about the Python-list mailing list