Closed mdakilansari closed 2 years ago
as i stumbled over this as well let me point you and other people looking for this to the correct place:
https://github.com/martinblech/xmltodict/blob/master/xmltodict.py#L266
set the force_list parameter on the parse method to either True to always return lists for all elements or provide a tuple with the tag names you do want as lists. works like a charm... just very much undocumented unless we consider the code documenting itself ;)
Format is wrong after conversion of List object with single value.
example:
{ "name": "ParameterName", "p": "10638" }
Expected:
{ "name": "ParameterName", "p": ["10638"] }
Please look into this issue. Attaching Sample XML snip for reference.
Thank you in advance.