Checklist
Steps to reproduce
In Django 1.8+, the template's render method takes a dictionary for the context parameter. Support for passing a Context instance is deprecated, and gives an error in Django 1.10+ (source1 / source2).
When adding a renderer to a generics.ListCreateAPIView, a TypeError: context must be a dict rather than ReturnList. pop.
To reproduce, create a simple Model+Serializer to fill data in a generics.ListCreateAPIView. Add a renderer_classes = [TemplateHTMLRenderer] to the ListView and try to access the page from a browser to render the template. Should crash (error 500 as an Exception is raised).
Expected behavior
The template should be rendered.
Actual behavior
A TypeError is thrown because context must be a dict rather than ReturnList
Checklist
masterbranch of Django REST framework.Steps to reproduce
In Django 1.8+, the template's render method takes a dictionary for the context parameter. Support for passing a Context instance is deprecated, and gives an error in Django 1.10+ (source1 / source2).
When adding a renderer to a
generics.ListCreateAPIView, aTypeError: context must be a dict rather than ReturnList.pop.To reproduce, create a simple Model+Serializer to fill data in a
generics.ListCreateAPIView. Add arenderer_classes = [TemplateHTMLRenderer]to the ListView and try to access the page from a browser to render the template. Should crash (error 500 as an Exception is raised).Expected behavior
The template should be rendered.
Actual behavior
A
TypeErroris thrown becausecontext must be a dict rather than ReturnList