-
Notifications
You must be signed in to change notification settings - Fork 71
Open
Description
Consider the following
1> Tuple = {{key, value}, { key2, {key3, [value1, 2,3]}}}.
{{key,value},{key2,{key3,[value1,2,3]}}}
Produces:
2> jsone:encode(Tuple).
** exception error: bad argument
in function jsone_encode:value/4
called as jsone_encode:value({{key,value},{key2,{key3,[value1,2,3]}}},
[],<<>>,
{encode_opt_v2,false,false,false,
[{scientific,20}],
{iso8601,0},
string,0,0,false,false,undefined})
in call from jsone:encode/2 (jsone.erl, line 382)
I think we should have a sensible default in these cases. Here is one suggestion:
{"key":"value", "key2, {"key3":["value1", 2,3]}}
How would one be able to pass on hints on how to handle certain conversion when default fails?
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels