[Bug 4078] addB156 - schemaLocation after first use of namespace

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4078

           Summary: addB156 - schemaLocation after first use of namespace
           Product: XML Schema Test Suite
           Version: 2006-11-06
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Microsoft tests
        AssignedTo: ht@inf.ed.ac.uk
        ReportedBy: mike@saxonica.com
         QAContact: public-xml-schema-testsuite@w3.org


In the Microsoft Additional test set, test group addB156 uses the instance
document test93490_2.xml, which contains the structure:

<foo:root 
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
        xsi:schemaLocation="foo test93490_1.xsd"        
        xmlns:foo="foo"
>

<foo:elem1 xsi:schemaLocation="foo test93490_2.xsd" xmlns:foo="foo"/>
<foo:elem2 />
<foo:elem3 />

</foo:root>

As it happens, validation of the instance does not require any schema
components from test93490_2.xsd.

The test results document this as invalid, presumably on the basis of the rule
in 4.3.2 rule 4: "xsi:schemaLocation and xsi:noNamespaceSchemaLocation
[attributes] can occur on any element. However, it is an error if such an
attribute occurs after the first appearance of an element or attribute
information item within an element information item initially ·validated· whose
[namespace name] it addresses. "

However, Schema Representation Constraint: Schema Document Location Strategy
says:

Given a namespace name (or none) and (optionally) a URI reference from
xsi:schemaLocation or xsi:noNamespaceSchemaLocation, schema-aware processors
may implement any combination of the following strategies, in any order:
1 Do nothing, for instance because a schema containing components for the given
namespace name is already known to be available...

A processor that follows this strategy will not report the error described in
the earlier section.

The specification appears to be internally inconsistent, and as a result this
test is not interoperable. (One could finesse the inconstency by deducing that
the spec says it's an error, and the spec also says that a processor isn't
required to do anything about the error; but the conclusion is the same.)

Received on Wednesday, 13 December 2006 18:04:16 UTC