Re: [D3E] Possible Changes to Mutation Events

On Jul 17, 2008, at 8:40 AM, Kartikaya Gupta wrote:

>
> Difficulty of implementations in general, yes. Difficulty of  
> individual implementations, no. There are countless other  
> implementations of MutationEvents out in the world (http://google.com/codesearch?hl=en&lr=&q=DOMNodeRemoved+-mozilla+-webcore&sbtn=Search 
> ). They exist in more languages and are used in more contexts than I  
> care to enumerate, and they don't seem to have this problem (also  
> think of the backwards-compatibility nightmare it would be to try  
> and update those implementations if they adopt this proposed D3E,  
> which means they probably won't).

Most of those search results are code that registers mutation event  
listeners, not implementations.

Looking at a few of the implementations, they appear to either be  
buggy in the face of mutation events that modify the DOM (will remove  
the node from the wrong parent if the mutation event moves it for  
example), or they fire DONodeRemoved after the mutation is fully or  
partially performed, or both. At least one of these was true of the  
Python DOM, libgdome, the tcl DOM and DOMJuan, the first 4 actual  
implementations that show up. The Python case is particularly  
egregious as it appears that it can leave the DOM in an inconsistent  
state.

It seems to me these search results are evidence that the current spec  
is too hard to implement.

Regards,
Maciej

Received on Thursday, 17 July 2008 22:18:55 UTC