#11378: Exceptions raised in Middleware process_request methods are not handled ---------------------------------------------+------------------------------ Reporter: ssdd | Owner: nobody Status: new | Milestone: Component: Core framework | Version: SVN Keywords: unhandled exception, middleware | Stage: Unreviewed Has_patch: 1 | ---------------------------------------------+------------------------------ In django.core.handlers.base.BaseHandler.get_response, running the Middleware process_request methods is done before the big try-except block that handles 404s and other exceptions. I'm not sure if this is intentional, but it makes it hard, for example, to send a standard 404 from process_request by raising Http404, as all exceptions raised here are unhandled and make it to the web server.
I've included a quick patch to fix this. I might be wrong. Thanks -- Ticket URL: <http://code.djangoproject.com/ticket/11378> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---
