[XML-SIG] SAX: Names with no namespace

Martin v. Loewis martin@loewis.home.cs.tu-berlin.de
Tue, 20 Feb 2001 19:47:03 +0100

> Which reminds me.  I've been told that getAttribute() and
> getAttributeNS() are supposed to return "" for a non-existent
> attribute, and that if you want to know whether the attribute was
> really there, you should use getAttributeNode() etc.  Again, that may
> be a good design for Java or IDL, but is it right for Python?  I'd
> much rather see None used as it was intended!

I'd have to check again, but I think the current DOM spec is painfully
clear about null and empty strings, and it also clear that a null
string ought to be None, and an empty string ought to be "". So there
is not much choice - except for developing a dislike towards the
entire DOM (which I wouldn't do just because of that problem).