Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


[xmlschema-dev]

From: "C B" <tsd60385@-------.-->
To: "xmlschema-dev" <xmlschema-dev@--.--->
Date: 5/25/2009 6:20:00 AM
Hi,

The XML Schema Validator
(http://www.w3.org/2001/03/webdata/xsv)
consistently crashes (see bug report copy/pasted below) when
submitting a local (i.e. non-web-based) schema with all 3 options (show
warnings, keep going, complete schema) selected.

Basically, I updated this part of a 400-lines schema that validates correctly:

<xs:simpleType name="lb" />

<xs:complexType name="pb">
   <xs:attribute name="n" type="xs:positiveInteger" use="required "/>
   <xs:attribute name="column" use="required">
               <xs:simpleType>
               <xs:restriction base="xs:string">
                       <xs:enumeration value="a"/>
                       <xs:enumeration value="b"/>
               </xs:restriction>
               </xs:simpleType>
   </xs:attribute>
</xs:complexType>

to this version that leads to the crash:

<xs:simpleType name="merge-split-word">
       <xs:restriction base="xs:string">
               <xs:enumeration value="keep-dash" />
               <xs:enumeration value="discard-dash" />
               <xs:enumeration value="no" />
       </xs:restriction>
</xs:simpleType>

<xs:complexType name="lb">
   <xs:attribute name="merge-split-word" type="merge-split-word" />
</xs:complexType>

<xs:complexType name="pb">
   <xs:attribute name="n" type="xs:positiveInteger" use="required "/>
   <xs:attribute name="column" use="required">
               <xs:simpleType>
               <xs:restriction base="xs:string">
                       <xs:enumeration value="a"/>
                       <xs:enumeration value="b"/>
               </xs:restriction>
               </xs:simpleType>
   </xs:attribute>
   <xs:attribute name="merge-split-word" type="merge-split-word" />
</xs:complexType>


Moreover, to obtain the bug report below, I had to select the "xml,
but labelled text/plain" option, as none of the 3 others would display
correctly the bug report (there was a short error message, but no
explanation or bug report).

Best regards,

C B




Bug report:

<?xml version='1.0'?>
<xsv xmlns="http://www.w3.org/2000/05/xsv" instanceAssessed="false"
    realName="fsml.xsd"
    schemaDocs="file:/usr/local/XSV/xsvlog/tmpo--ff7uploaded" schemaErrors="0"
    target="[standalone schema assessment]"
    version="XSV 3.1-1 of 2007/12/11 16:20:05">
 <schemaDocAttempt URI="file:///usr/local/XSV/xsvlog/tmpo--ff7uploaded"
                   outcome="failure" source="command line"/>
 <bug>validator crash during command line:
Traceback (most recent call last):
 File "/usr/local/XSV/src/XSV/compile/SSchema.py", line 672, in checkinSchema
   res=self.fromFile(loc,frag,namespace,why,btlist,ne,useDTD,keepGoing)
 File "/usr/local/XSV/src/XSV/compile/SSchema.py", line 400, in fromFile
   sdoc.documentElement)
 File "/usr/local/XSV/src/XSV/infoset/relNorm/rebuild.py", line 290,
in fromFile
   res=self.processElement(root)
 File "/usr/local/XSV/src/XSV/infoset/relNorm/rebuild.py", line 374,
in processElement
   eres.append(self.processElement(d))
 File "/usr/local/XSV/src/XSV/infoset/relNorm/rebuild.py", line 374,
in processElement
   eres.append(self.processElement(d))
 File "/usr/local/XSV/src/XSV/infoset/relNorm/rebuild.py", line 412,
in processElement
   res.init(elt)
 File "/usr/local/XSV/src/XSV/compile/elts/attributeElt.py", line 23, in init
   defRefElt.init(self,'attribute',attributeGroupElt,('ref',))
 File "/usr/local/XSV/src/XSV/compile/elts/defRefElt.py", line 25, in init
   self.checkInternal()
 File "/usr/local/XSV/src/XSV/compile/elts/attributeElt.py", line 60,
in checkInternal
   self.use or 'optional',vct,value)
 File "/usr/local/XSV/src/XSV/compile/AttributeUse.py", line 28, in __init__
   (self.minOccurs,self.maxOccurs)=_attrOccurs[use]
KeyError: u'required '
</bug>
</xsv>


_________________________________________
Tired of download limits?
Scarlet NO LIMIT, now only 19,95 EUR
Go to www.scarlet.be for more info!





transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent