Re: [indexeddb] New WebIDL Exception Model for IndexedDB

On Thu, 29 Sep 2011 23:54:50 +0200, Israel Hilerio <>  
> Microsoft believes that the following text closer reflects the intent on  
> the WebIDL spec:
> * Throws a DOMException of type " VersionError".
> (vs. Throw a VersionError exception, which doesn’t accurately capture  
> the intent defined in the WebIDL spec)

Actually, given it  
does. Which is what I was trying to convey. HTML does this too now:

> As we mentioned before, we agree on the reuse of existing DOM level 4  
> Exceptions currently contained in the spec.  However, it is our stance  
> that feature specific exceptions should be defined in the spec that they  
> are used in.  With the new WebIDL model, it’s not necessary to “define”  
> the exceptions anywhere. Anyone can just state in their spec: "Throw a  
> DOMException of type FooBar" and that’s it.

Yes, but how do you prevent e.g. WrongVersionError from appearing next to  
VersionError if there is no central lookup? Do you expect people that mint  
new exceptions to look at all specifications that use exceptions? The  
exceptions defined in DOM4 are already not specific to DOM4, e.g.  
NetworkError is mostly for XMLHttpRequest at this point, as is  

> This is the pattern we're looking to follow for IndexedDB.

Anne van Kesteren

Received on Friday, 30 September 2011 07:23:21 UTC