We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3c02f8f commit 94e0cd7Copy full SHA for 94e0cd7
readthedocs/core/views/__init__.py
@@ -107,8 +107,14 @@ def server_error_500(request, template_name='500.html'):
107
return r
108
109
110
-def server_error_404(request, exception, template_name='404.html'): # pylint: disable=unused-argument # noqa
111
- """A simple 404 handler so we get media."""
+def server_error_404(request, exception=None, template_name='404.html'): # pylint: disable=unused-argument # noqa
+ """
112
+ A simple 404 handler so we get media.
113
+
114
+ .. note::
115
116
+ Marking exception as optional to make /404/ testing page to work.
117
118
response = get_redirect_response(request, path=request.get_full_path())
119
if response:
120
return response
0 commit comments