- From: Michael Kay <mike@saxonica.com>
- Date: Sat, 24 Nov 2012 22:06:19 +0000
- To: xmlschema-dev@w3.org
- Message-ID: <50B144DB.6020007@saxonica.com>
This is what Saxon has to say about the schema at http://www.w3.org/2011/04/SCXML/scxml.xsd Error on line 281 of scxml-module-core.xsd: Error in complex type scxml.if.type: Ambiguous content model, element <Q{.../scxml}cancel> appears in its own right, and also matches an <xs:any> wildcard The error goes away if you specify -xsdversion:1.1 So it appears that this schema requires an XSD 1.1 processor. I suggest you raise a comment against the SCXML specification suggesting that they alert the reader to this fact. It's quite possible that the authors of the schema only tested it using an XSD 1.1 processor, or an XSD 1.0 processor that isn't fully conformant with the specification: sadly, such processors are in widespread use. Michael Kay Saxonica On 24/11/2012 13:45, Carlos Verdes wrote: > Hi, > > I'm validating a scxml and getting a validation error which I don't > think it is. > > The xml extract is: > <scxml xmlns="http://www.w3.org/2005/07/scxml" > xmlns:a="http://www.nosolojava.com/android.scxml" > xmlns:xmpp="http://www.nosolojava.com/xmpp.scxml" > version="1.0" > > ... > > <!-- history state --> > <history id="history-conn-state"> > <transition target="chat-connected-idle" /> > </history> > > The error is on history tag: > cvc-complex-type.2.4.b: The content of element 'history' is not > complete. One of '{WC[##any], > "http://www.w3.org/2005/07/scxml":transition}' is expected. > > This has no sense because the transition element is present. > > I have checked the schema: > <xsd:group name="scxml.history.content"> > <xsd:sequence> > <xsd:group ref="scxml.extra.content" minOccurs="0" > maxOccurs="unbounded"/> > <xsd:element ref="transition" minOccurs="1" maxOccurs="1"/> > <xsd:group ref="scxml.extra.content" minOccurs="0" > maxOccurs="unbounded"/> > </xsd:sequence> > </xsd:group> > > > and.. the curious point is if I delete the first group in the > secuence... the error disapears!! > <xsd:group name="scxml.history.content"> > <xsd:sequence> > <xsd:element ref="transition" minOccurs="1" maxOccurs="1"/> > <xsd:group ref="scxml.extra.content" minOccurs="0" > maxOccurs="unbounded"/> > </xsd:sequence> > </xsd:group> > > Any advice?
Received on Saturday, 24 November 2012 22:06:41 UTC