Hi
I thought I’d make my own heatmap using custom events for debug during testing. I exported some custom event data from Unity Analytics, went to load it in the JSON parser in Unity and got an error “JSON parse error: The document root must not follow by other values.”
I copied the JSON output from the portal into various JSON validators, they all came back fail. Multiple JSON root elements
Analytics raw output is like this:
{“name”:“event”,“userid”:“123”}
{“name”:“event”,“userid”:“123”}
{“name”:“event”,“userid”:“123”}
so Isn’t valid JSON. Shouldn’t it output something like this?
[{“name”:“event”,“userid”:“123”},
{“name”:“event”,“userid”:“123”},
{“name”:“event”,“userid”:“123”}]
Thanks
coshea_1:
Hi
I thought I’d make my own heatmap using custom events for debug during testing. I exported some custom event data from Unity Analytics, went to load it in the JSON parser in Unity and got an error “JSON parse error: The document root must not follow by other values.”
I copied the JSON output from the portal into various JSON validators, they all came back fail. Multiple JSON root elements
Analytics raw output is like this:
{“name”:“event”,“userid”:“123”}
{“name”:“event”,“userid”:“123”}
{“name”:“event”,“userid”:“123”}
so Isn’t valid JSON. Shouldn’t it output something like this?
[{“name”:“event”,“userid”:“123”},
{“name”:“event”,“userid”:“123”},
{“name”:“event”,“userid”:“123”}]
Thanks
It seems some error occurred at that time, could you try it again?
Each data row in Raw Data Export is it’s own JSON document, by design.
Hi, i am also facing same issue. How to fix it? Please help
The Raw Data Export uses newline delimited json so each line represents a valid JSON value: