Forum OpenACS Development: Re: From database to JSON

Collapse
Posted by Neophytos Demetriou on
Hi Rolf, at my morning coffee and I cannot stop thinking of the segfaults you reported. I am using tcl9 both on linux and macos without any build warnings or segfaults. So, I kindly asked Konstantin to independently check and I will post again when he does.

Unless tcl9 is installed at /usr/local you need to provide TCL_LIBRARY_DIR and TCL_INCLUDE_DIR as discussed in the readme.md. I am not 100% sure you did that as I see you load the shared library with load instead of package require. If you were to provide more details, we can fix things, which is on us to make it work for everyone.

That said, I guess we should call up amazon to stop using cjson in their c++ sdk. And, by that I mean, I am glad tdom passes all tests but it is no reason for me to switch to tdom-json. I am using tdom for xml as you know already.

Furthermore, I finally figured out why arrays in tdom were not working for me. I was using xml manipulation commands to create the array without creating an "arraycontainer" node.

Collapse
Posted by Rolf Ade on
The seg faults was my fauilt - I was stupid, absently and careless to mix up a Tcl 9 shell with a Tcl 8.6 linked extension. And not to imediately realize that.
Sorry for the noise.
Collapse
Posted by Neophytos Demetriou on
Thanks for clarifying. I think tdom is great and I must admit I learnt a lot by studying its code. I also think the more extensions, the better for the TCL ecosystem.