`ValidationError` field names are not camelized
l0b0 opened this issue · comments
Victor Engmark commented
When I raise rest_framework.serializers.ValidationError({'some_field_name': 'some message'})
the resulting API response is {'some_field_name': [ErrorDetail(string='some message', code='invalid')]}
. The expected response would be {'someFieldName': [ErrorDetail(string='some message', code='invalid')]}
.
Vitaly Babiy commented
Those errors look like they are on the python side, not the JSON response. The render doesn't touch them at that point.