-
-
Notifications
You must be signed in to change notification settings - Fork 7k
Fix issue #5258 #5259
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix issue #5258 #5259
Conversation
Sanitize serializer.data to remove hidden fields before rendering template JSON instance to raw data form.
Thanks @elmccarthy - seems pretty clear-cut. 😄 |
I think this PR breaks serializers from the djangorestframework-gis add-on. This add-on serializes model objects into a GeoJSON-compatible |
@seav First step here is a test showing the kind of call that is failing but shouldn't. From there we can think about adjustments. |
Seconding the djangorestframework-gis issue, ran into this today. Reported at openwisp/django-rest-framework-gis#145 |
Hi @jklaiho and @seav, I'm going to second @carltongibson here. It would be very helpful to have a minimal test case or a bit of sample code that demonstrates the issue. |
@carltongibson @rpkilby Here's a minimal Django project I cooked up to demonstrate this: |
This reverts commit b905197.
Thanks @jklaiho, that and #5498 clarified the problem. To recap, django-rest-framework-gis, does not use |
Description
Sanitize
serializer.data
to remove hidden fields before rendering templateJSON instance to raw data form.
refs #5258
closes #5258