I had a slightly related issue, of trying to pass a array from a pre request script via pm.variables.set. I solved it by doing
JSON.stringify
on the array, seems to work!