We are using @schema.validate on our controllers.
A property defined as
"properties": {
"probability_list": {
"type": "array"
}
}
will unfortunately fail in case a Python tuple is passed instead of a list. json.dumps will always transform Python tuples to list, so I don't see why validate should raise an exception on encountering a tuple.
Any insight on how to solve this without having to transform all of my tuples into list before outputting them?
We are using
@schema.validateon our controllers.A property defined as
will unfortunately fail in case a Python tuple is passed instead of a list.
json.dumpswill always transform Python tuples to list, so I don't see whyvalidateshould raise an exception on encountering a tuple.Any insight on how to solve this without having to transform all of my tuples into list before outputting them?