Strange, Inconsistent Errors Parsing XBRL Schemas

Michael Pigott <[email protected]> Sun, 10 Nov 2013 19:53:01 -0500
Newsgroups gmane.text.xml.xmlbeans.user
Message-ID <CAKNYV3kUj1UQbWczTHofufehb2RQnansJSmBvJVzLnz9stVR1w@mail.gmail.com>
--047d7bb04a065ea0b904eadc27b5
Content-Type: text/plain; charset=ISO-8859-1

Hello,
   I'm getting inconsistent behavior when trying to generate schemas for
the US GAAP XBRL documents.  When I download the requisite GAAP documents
to a local directory, and run the following command:

======================
>scomp -out gaap.jar us-gaap-2013-01-31.xsd -compiler
"%JAVA_HOME%\bin\javac" -verbose -dl
Apache Software Foundation, org.apache.xmlbeans.XmlBeans version
2.5.0-r882429
Loading schema file us-gaap-2013-01-31.xsd
Loading referenced file
http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd
Loading referenced file us-types-2013-01-31.xsd
Loading referenced file us-roles-2013-01-31.xsd
Loading referenced file http://www.xbrl.org/2005/xbrldt-2005.xsd
Loading referenced file http://www.xbrl.org/2006/ref-2006-02-27.xsd
Loading referenced file http://www.xbrl.org/dtr/type/numeric-2009-12-16.xsd
Loading referenced file
http://www.xbrl.org/dtr/type/nonNumeric-2009-12-16.xsd
Loading referenced file
http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd
Loading referenced file http://www.xbrl.org/2003/xl-2003-12-31.xsd
Loading referenced file http://www.xbrl.org/2003/xlink-2003-12-31.xsd
http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5: error:
derivation-ok-restriction.4.2: The anyAttribute namespace='##other' is not
a subset of the base type anyAttribute.
http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5: error:
derivation-ok-restriction.4.2: The anyAttribute namespace='##other' is not
a subset of the base type anyAttribute.
http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5: error:
derivation-ok-restriction.4.2: The anyAttribute namespace='##other' is not
a subset of the base type anyAttribute.
Time to build schema type system: 6.003 seconds
BUILD FAILED
======================

However, if I download
http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsdand all of the
other schemas referenced, and just parse that one locally:

scomp -out xbrl.jar -compiler "%JAVA_HOME%\bin\javac" -dl -verbose
xbrl-instance-2003-12-31.xsd

The parser runs without error and successfully generates xbrl.jar.

Do you know what the problem is?

If you want to reproduce, the US GAAP Schema file can be downloaded from
http://xbrl.fasb.org/us-gaap/2013/elts/us-gaap-2013-01-31.xsd and it relies
on http://xbrl.fasb.org/us-gaap/2013/elts/us-roles-2013-01-31.xsd and
http://xbrl.fasb.org/us-gaap/2013/elts/us-types-2013-01-31.xsd.

I'm using XMLBeans v. 2.5.0.

Thanks, and please let me know if you need anything else!
Mike

--047d7bb04a065ea0b904eadc27b5
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hello,<div>=A0 =A0I&#39;m getting inconsistent behavior wh=
en trying to generate schemas for the US GAAP XBRL documents. =A0When I dow=
nload the requisite GAAP documents to a local directory, and run the follow=
ing command:</div>
<div><br></div><div>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D<br></div><div><div>&gt;scomp -out gaap.jar us-gaap-2013-01-31.=
xsd -compiler &quot;%JAVA_HOME%\bin\javac&quot; -verbose -dl</div><div>Apac=
he Software Foundation, org.apache.xmlbeans.XmlBeans version 2.5.0-r882429<=
/div>
<div>Loading schema file us-gaap-2013-01-31.xsd</div><div>Loading reference=
d file <a href=3D"http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd">ht=
tp://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd</a></div><div>Loading r=
eferenced file us-types-2013-01-31.xsd</div>
<div>Loading referenced file us-roles-2013-01-31.xsd</div><div>Loading refe=
renced file <a href=3D"http://www.xbrl.org/2005/xbrldt-2005.xsd">http://www=
.xbrl.org/2005/xbrldt-2005.xsd</a></div><div>Loading referenced file <a hre=
f=3D"http://www.xbrl.org/2006/ref-2006-02-27.xsd">http://www.xbrl.org/2006/=
ref-2006-02-27.xsd</a></div>
<div>Loading referenced file <a href=3D"http://www.xbrl.org/dtr/type/numeri=
c-2009-12-16.xsd">http://www.xbrl.org/dtr/type/numeric-2009-12-16.xsd</a></=
div><div>Loading referenced file <a href=3D"http://www.xbrl.org/dtr/type/no=
nNumeric-2009-12-16.xsd">http://www.xbrl.org/dtr/type/nonNumeric-2009-12-16=
.xsd</a></div>
<div>Loading referenced file <a href=3D"http://www.xbrl.org/2003/xbrl-linkb=
ase-2003-12-31.xsd">http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd</=
a></div><div>Loading referenced file <a href=3D"http://www.xbrl.org/2003/xl=
-2003-12-31.xsd">http://www.xbrl.org/2003/xl-2003-12-31.xsd</a></div>
<div>Loading referenced file <a href=3D"http://www.xbrl.org/2003/xlink-2003=
-12-31.xsd">http://www.xbrl.org/2003/xlink-2003-12-31.xsd</a></div><div><a =
href=3D"http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5">http:/=
/www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5</a>: error: derivatio=
n-ok-restriction.4.2: The anyAttribute namespace=3D&#39;##other&#39; is not=
 a subset of the base type anyAttribute.</div>
<div><a href=3D"http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5=
">http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5</a>: error: d=
erivation-ok-restriction.4.2: The anyAttribute namespace=3D&#39;##other&#39=
; is not a subset of the base type anyAttribute.</div>
<div><a href=3D"http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5=
">http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd:175:5</a>: error: d=
erivation-ok-restriction.4.2: The anyAttribute namespace=3D&#39;##other&#39=
; is not a subset of the base type anyAttribute.</div>
<div>Time to build schema type system: 6.003 seconds</div><div>BUILD FAILED=
</div></div><div>=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D</div><div><br></div><div>However, if I download <a href=3D"http:/=
/www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd">http://www.xbrl.org/2003/x=
brl-instance-2003-12-31.xsd</a> and all of the other schemas referenced, an=
d just parse that one locally:</div>
<div><br></div><div>scomp -out xbrl.jar -compiler &quot;%JAVA_HOME%\bin\jav=
ac&quot; -dl -verbose xbrl-instance-2003-12-31.xsd<br></div><div><br></div>=
<div>The parser runs without error and successfully generates xbrl.jar.</di=
v>
<div><br></div><div>Do you know what the problem is?</div><div><br></div><d=
iv>If you want to reproduce, the US GAAP Schema file can be downloaded from=
=A0<a href=3D"http://xbrl.fasb.org/us-gaap/2013/elts/us-gaap-2013-01-31.xsd=
">http://xbrl.fasb.org/us-gaap/2013/elts/us-gaap-2013-01-31.xsd</a>=A0and i=
t relies on=A0<a href=3D"http://xbrl.fasb.org/us-gaap/2013/elts/us-roles-20=
13-01-31.xsd">http://xbrl.fasb.org/us-gaap/2013/elts/us-roles-2013-01-31.xs=
d</a>=A0and=A0<a href=3D"http://xbrl.fasb.org/us-gaap/2013/elts/us-types-20=
13-01-31.xsd">http://xbrl.fasb.org/us-gaap/2013/elts/us-types-2013-01-31.xs=
d</a>.</div>
<div><br></div><div>I&#39;m using XMLBeans v. 2.5.0.</div><div><br></div><d=
iv>Thanks, and please let me know if you need anything else!</div><div>Mike=
</div></div>

--047d7bb04a065ea0b904eadc27b5--