[x3d-public] Bug in Savage/Scenarios X3D XML Examples (likely). Not producing valid JSON
John Carlson
yottzumm at gmail.com
Sun Apr 11 20:49:43 PDT 2021
X3dToJson.xlst appears to be generating a bad JSON string array for
NavigationInfo @type?
Original X3D XML looks like:
LimitedObjectiveExperimentPortHuenemeDIS.x3d: <NavigationInfo speed='10'
type='EXAMINE" "FLY" "ANY' visibilityLimit='30000'/>
LimitedObjectiveExperimentPortHueneme.x3d: <NavigationInfo
avatarSize='2 1.6 .75' speed='10' type='EXAMINE" "FLY" "ANY'
visibilityLimit='30000'/>
There are other, different examples in the same folder that used the old
way of doing an MFString.
I'm not sure what a valid XML MFString is any more (see the type
attribute in both cases), please don't direct me to a web site, just
output good JSON, thanks!
No obvious error or warning noted in meta.
Note, I have begun stripping off "/c/x3d-code/www.web3d.org" from the
file names I post in order that a good filename is retained. Let me know
if this is working.
Maybe instead of being known as QA Specialist, I should be known as a
Errorist? Lol!
John
$ jsonlint
x3d/content/examples/Savage/Scenarios/LimitedObjectiveExperimentPortHueneme/LimitedObjectiveExperimentPortHueneme.json
Error: Parse error on line 241:
... "@type":["EXAMINE" "FLY" "ANY"],
-----------------------^
Expecting 'EOF', '}', ':', ',', ']', got 'STRING'
at Object.parseError
(/usr/local/lib/node_modules/jsonlint/lib/jsonlint.js:55:11)
at Object.parse
(/usr/local/lib/node_modules/jsonlint/lib/jsonlint.js:132:22)
at parse (/usr/local/lib/node_modules/jsonlint/lib/cli.js:82:14)
at main (/usr/local/lib/node_modules/jsonlint/lib/cli.js:135:14)
at Object.<anonymous>
(/usr/local/lib/node_modules/jsonlint/lib/cli.js:179:1)
at Module._compile (internal/modules/cjs/loader.js:1138:30)
at Object.Module._extensions..js
(internal/modules/cjs/loader.js:1158:10)
at Module.load (internal/modules/cjs/loader.js:986:32)
at Function.Module._load (internal/modules/cjs/loader.js:879:14)
at Function.executeUserEntryPoint [as runMain]
(internal/modules/run_main.js:71:12)
$ jsonlint
x3d/content/examples/Savage/Scenarios/LimitedObjectiveExperimentPortHueneme/LimitedObjectiveExperimentPortHuenemeDIS.json
Error: Parse error on line 260:
... "@type":["EXAMINE" "FLY" "ANY"],
-----------------------^
Expecting 'EOF', '}', ':', ',', ']', got 'STRING'
at Object.parseError
(/usr/local/lib/node_modules/jsonlint/lib/jsonlint.js:55:11)
at Object.parse
(/usr/local/lib/node_modules/jsonlint/lib/jsonlint.js:132:22)
at parse (/usr/local/lib/node_modules/jsonlint/lib/cli.js:82:14)
at main (/usr/local/lib/node_modules/jsonlint/lib/cli.js:135:14)
at Object.<anonymous>
(/usr/local/lib/node_modules/jsonlint/lib/cli.js:179:1)
at Module._compile (internal/modules/cjs/loader.js:1138:30)
at Object.Module._extensions..js
(internal/modules/cjs/loader.js:1158:10)
at Module.load (internal/modules/cjs/loader.js:986:32)
at Function.Module._load (internal/modules/cjs/loader.js:879:14)
at Function.executeUserEntryPoint [as runMain]
(internal/modules/run_main.js:71:12)
This pretty much concludes all of the X3D JSON parsing errors I found
with my tools.
I think the X3D examples are pretty much good to go except for the last
5 problems noted.
We are now progressing into how the X3D JSON schema is documented.
John
More information about the x3d-public
mailing list