Error handling rules?

http://www.w3.org/TR/2001/WD-xinclude-20010516/

I was very impressed overall by this spec. The only thing that I
consider is missing from the specification is a normative section
explaining how errors should be handled.

If an XInclude-conforming UA attempts to use the following ill-formed
XML document:

   <foo></bar>

...then it should (per XML) refuse to process the document further.

What should happen if an XInclude-conforming UA attempts to use the
following well-formed but non-XInclude-conforming document?

   <include xmlns="http://www.w3.org/1999/XML/xinclude"
      parse="html" href="hello.html"/>

Should it refuse to handle the document at all? Should it silently
ignore it? Should it embed a predefined infoset containing an error
message? For interoperability I highly recommend defining standard
error handling behaviour (as XML and CSS do, for example).

(Also, if the root of an XML document is an xi:include element with
parse="text", is that an error? The only case the spec currently
mentions is that of replacing a root element with two or more
elements, there is no mention of replacing the root element with
anything else that would make the document ill-formed.)

Cheers,
-- 
Ian Hickson                                            )\     _. - ._.)   fL
Invited Expert, CSS Working Group                     /. `- '  (  `--'
The views expressed in this message are strictly      `- , ) -  > ) \
personal and not those of Netscape or Mozilla. ________ (.' \) (.' -' ______

Received on Tuesday, 22 May 2001 17:27:14 UTC