[XML-SIG] Working around problems in older DOM implementations

Martin v. Löwis martin@v.loewis.de
29 Mar 2003 17:13:17 +0100


Andrew Clover <and-xml@doxdesk.com> writes:

> I'm using DOM Level 2 Namespace-aware Core methods only, with an importer
> layer that fixes up known bugs in widely-deployed DOMs. I've checked minidom
> from Python 2.1 and 4DOM from PyXML 0.6.6 so far, and added workarounds for
> the following problems:
> 
>   - minidom: no native importNode support

You should use PyXML; minidom has importNode support.

>   - minidom: insertBefore/appendChild/replaceChild with DocumentFragment
>     Node fails to insert all new children due to destructive list iteration

That appears to be fixed in PyXML as well.

>   - minidom: attributes in no namespace get '' namespaceURI instead of None.
>     Elements and attributes in no namespace get '' prefix instead of None.

Can't reproduce this with PyXML.

> Are there any other known problems with common DOMs I ought to be looking
> out for?

Most certainly. However, it is better to fix the bugs instead of
listing them. Please make bug reports for any bugs you find.

Regards,
Martin