#12502: Diagram doesn't match text in Middleware documentation
-------------------------------+------------------------------------
Reporter: petrilli | Owner:
Type: Bug | Status: new
Component: Documentation | Version: master
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1
Easy pickings: 0 | UI/UX: 0
-------------------------------+------------------------------------
Comment (by aaugustin):
We have to strike a balance between completeness and clarity. This graph
is displayed at the beginning of the introduction to middleware and should
be understandable at first sight. For this reason, I wouldn't attempt to
show that each middleware can short-circuit the rest of the chain by
returning a response in `process_request/view/exception`. It's clearly
explained in the text and rather intuitive.
However, there's another aspect that I'd like to represent:
`process_template_response` and `process_response` are applied after
`process_exception`. The current docs describe `process_exception` at the
end — they start with the common case; that can be confusing. They repeat
that "Response middleware is always called on every response" but the
concrete result is difficult to understand (at least for me) without a
visual representation.
I'm attaching (yet another) SVG file that implements these ideas and tries
not to be too ugly.
--
Ticket URL: <https://code.djangoproject.com/ticket/12502#comment:16>
Django <https://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 https://groups.google.com/groups/opt_out.