You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to specify the type of the key when converting to JSON? I have csv columns which are integers and boolean. When i use this module to convert csv to json, those values are outputted as strings.
{
"number": "240",
"isdown": "FALSE"
}
I am excepting
{
"number": 240,
"isdown": false
}
The text was updated successfully, but these errors were encountered:
@ammuluk
Apologies for the late response! @rossw7 has opened #6 to deal with integer values.
Booleans will be a little bit tricky because there is no standard way to represent a boolean value in a CSV file (ex: true can be True, TRUE, true, yes, YES, Yes, etc), but it would be interesting to add some sort of option to let the user manually specify which values should be type converted (ex: {'bool': {False: ['No', 'no', ...], True: ['YES', 'yes', ...]} }).
Is there a way to specify the type of the key when converting to JSON? I have csv columns which are integers and boolean. When i use this module to convert csv to json, those values are outputted as strings.
{
"number": "240",
"isdown": "FALSE"
}
I am excepting
{
"number": 240,
"isdown": false
}
The text was updated successfully, but these errors were encountered: