<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>I decided to let loose the new JSON validator/schema on my local
files.</p>
<p>I got the following:</p>
<p>~/X3DJSONLD/src/main/schema$ node ~/x3dvalidate/x3dvalidate.js
../data/*.json 2>&1 |grep Error</p>
<p>Error reading ../data/AllAudioGraphNodesTest.json <br>
Error reading ../data/AllAudioGraphNodesTest.new.json <br>
Error reading ../data/Filters.json <br>
<b>Error reading ../data/rubik2x2x2.json </b><b><br>
</b><b>Error reading ../data/rubikcoord.json </b><br>
Error reading ../data/SpatialAudioCameraAnimation.json <br>
Error reading ../data/SpatialAudioCameraAnimation.new.json</p>
<p><br>
</p>
<p>The audio files seem to be a well known quantity, as previously
reported on this email list.<br>
</p>
<p>For the other files, the rubik files in particular, there are
some specific errors that may need to be added to X3DUOM, not
sure. As previously noted, the schema reports that the IS is not
an allowed node below fieldValue. I'm not sure where we left
putting IS below fieldValue? I thought we voted in favor of
putting IS below fieldValue, but I'm not seeing it in X3DUOM yet
(Am I missing something?). Attaching .x3d.</p>
<p>
</p>
<p>I realize that the .x3d does not pass X3D validator. There may
be other issues with the XML that are not legal. One may attempt
to convert the XML to JSON with X3D-Edit, I believe.</p>
<p>Note: freewrl seems to be the best viewer for the the attached
file. I tried X3DJSONLD, FreeWRL and view3dscene. I'm still
working on web browsing JSON validation. Someone with experience
creating bundles from Node.js modules could help a bit. Or
otherwise getting Ajv2020-12 to work in a browser.<br>
</p>
<p>JSON Schema validation of rubik2x2x2 file (other is similar):</p>
<p>~/X3DJSONLD/src/main/schema$ node ~/x3dvalidate/x3dvalidate.js
../data/rubik2x2x2.json <br>
Can only validate version 4.0 presently. Switching version to 4.0.<br>
Loading schema<br>
Parsing schema<br>
Adding schema<br>
Schema 4.0 added<br>
Schema 4.0 compiled<br>
================================================================================<br>
File: ../data/rubik2x2x2.json<br>
Error reading ../data/rubik2x2x2.json <br>
keyword: required<br>
instancePath:
/X3D/Scene/-children/3/ProtoDeclare/ProtoBody/-children/0/Transform<br>
message: must have required property @USE<br>
params: {"missingProperty":"@USE"}<br>
file: ../data/rubik2x2x2.json<br>
version: 3.3<br>
<br>
keyword: required<br>
instancePath:
/X3D/Scene/-children/3/ProtoDeclare/ProtoBody/-children/0/Transform/-children/0/ProtoInstance<br>
message: must have required property @USE<br>
params: {"missingProperty":"@USE"}<br>
file: ../data/rubik2x2x2.json<br>
version: 3.3<br>
<br>
keyword: additionalProperties<br>
instancePath:
/X3D/Scene/-children/3/ProtoDeclare/ProtoBody/-children/0/Transform/-children/0/ProtoInstance/fieldValue/1<br>
message: must NOT have additional properties<br>
params: {"additionalProperty":"IS"}<br>
file: ../data/rubik2x2x2.json<br>
version: 3.3<br>
<br>
keyword: oneOf<br>
instancePath:
/X3D/Scene/-children/3/ProtoDeclare/ProtoBody/-children/0/Transform/-children/0/ProtoInstance<br>
message: must match exactly one schema in "oneOf"<br>
params: {"passingSchemas":null}<br>
file: ../data/rubik2x2x2.json<br>
version: 3.3<br>
<br>
keyword: oneOf<br>
instancePath:
/X3D/Scene/-children/3/ProtoDeclare/ProtoBody/-children/0/Transform<br>
message: must match exactly one schema in "oneOf"<br>
params: {"passingSchemas":null}<br>
file: ../data/rubik2x2x2.json<br>
version: 3.3<br>
</p>
</body>
</html>