Open gordonwoodhull opened 9 years ago
would prefer to fix this at the rserve.js level... i know, another big refactoring, but we are special casing everything that can be an array of size one to work around the way rserve.js thinks it's a scalar.
From @cscheid on May 6, 2014 18:8
I'd like to not change json
if possible. maybe the solution is to allow a function to return the unconverted raw javascript object from rserve-js. Right now everything in ocap mode calls json.
Yeah, I'm thinking that ideally clients of rserve.js could register that they want particular parameters really to be arrays and not scalarized. I don't know how this would happen though.
I wouldn't want to change it everywhere, agreed. Usually what looks like a scalar, is.
To contradict myself: we are working around arrays of size one being interpreted as scalars, all over the place. Do that again here.
From @cscheid on May 6, 2014 17:53
Factors with a single level get interpreted by wdcplot as many levels of a single character each. This likely has to do with
rserve-js
'sjson
function doing the wrong thing.Copied from original issue: att/rcloud#627