What XML lib to use?

Magnus Lycka lycka at carmen.se
Wed Sep 14 18:36:00 CEST 2005


Fredrik Lundh wrote:
> since there are no *sane* reasons to use SAX or DOM in Python, that's mainly
> a job security issue...

I can see two reasons (sane or not):
  - You're familiar with those APIs and use them in e.g. C++.
  - You don't want to rely on third party libraries unless you must.

In many cases, xml.dom.minidom etc will do fine...

Having said this, I must admit that I much prefer Fredrik's ElementTree.

Although Fredrik (did you know that?) had a part in Carmen's move to
Python around five years ago, ElementTree isn't installed by default
on our machines, and I think our CM people are happier if we use as
few third party libraries as possible...



More information about the Python-list mailing list