These are chat archives for django/django

Apr 2015
Mitchel Cabuloy
Apr 07 2015 10:58
Hey guys. I have a quick question. So I added these lines to my main
handler404 = TemplateView.as_view(template_name='404.html')
handler500 = TemplateView.as_view(template_name='500.html')
I do have a 404.html and 500.html template at the top of one of my template directories, but for some reason, it errors out. ContentNotRenderedError: The response content must be rendered before it can be iterated over.
Can anyone shed some light as to what's happening here? Based on my research, this is all that's needed for custom 404/500 views, right?
Mir Nazim
Apr 07 2015 11:06
Why are you assigning a custom view function. Just create a 404.html in the root of your template dir
Mitchel Cabuloy
Apr 07 2015 11:09
Alright well, I'm not getting any errors now that I've commented those lines out. I'm using runserver to test, and it's just returning a blank page instead of my 404 page
I'll try using watiress
Mitchel Cabuloy
Apr 07 2015 11:16
And same deal, blank page
Mitchel Cabuloy
Apr 07 2015 11:26
I found the problem, an INSTALLED_APP was conflicting. It, probably had it's own 404 page. :fire: