[x3d-public] x3d.py SFVec3f toXML keeps parens

John Carlson yottzumm at gmail.com
Sun Apr 26 11:16:14 PDT 2020


Suggest slurping JSON into X3DJSAIL/X3DJSONLD.java (convert to DOM tree)
for JSON validation instead of schema.

Thanks

John

On Sat, Apr 25, 2020 at 11:06 AM Don Brutzman <brutzman at nps.edu> wrote:

> [cc: x3d-public with permission]
>
> Andreas thank you for another helpful issue report.
>
> On 4/23/2020 7:40 PM, Andreas Plesch wrote:
> > Sorry but I keep coming across these (with 0.0.27):
>
> No really thanks, my regression testing so far only checks for exceptions,
> haven't done any round-trip tests which will take some nontrivial work.
>
> >>>> import x3d.x3d as x
> > x3d.py package loaded, have fun with X3D Graphics!
> >>>> x.Viewpoint(position=(1,1,1)).toXML()
> > "<Viewpoint position='(1, 1, 1)'/>\n"
> >>>>
> >
> > The output should be <Viewpoint position='1, 1, 1'/> .
>
> This is common problem/correction for all SFVec3f and similarly all
> numeric types and most MF types.  Will need to be extra careful (as usual)
> with SFString and MFString.
>
> TODO, hopefully this weekend: will be changing output to match X3D
> canonical form, <Viewpoint position='1, 1, 1'/>
>
> Additional error patterns also welcome.  Strict typing of X3D scene graph
> plus Pythonic strictness plus Quality Assurance (QA) will lead us to a
> really robust pipeline, suitable even for Big Data information flows.  Java
> has this rigor already, XML is similarly strong, when JSON Schema is
> finally standardized/deployed then that alternative dataflow will be ready
> for "prime time" application chains as well.
>
> p.s. motivation: the worst errors are those you don't know about because
> they fail silently.
>
> all the best, Don
> --
> Don Brutzman  Naval Postgraduate School, Code USW/Br
> brutzman at nps.edu
> Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA   +1.831.656.2149
> X3D graphics, virtual worlds, navy robotics
> http://faculty.nps.edu/brutzman
>
> _______________________________________________
> x3d-public mailing list
> x3d-public at web3d.org
> http://web3d.org/mailman/listinfo/x3d-public_web3d.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20200426/a0f66a7e/attachment-0001.html>


More information about the x3d-public mailing list