Opened 17 years ago
Closed 17 years ago
#6679 closed (fixed)
decorator_from_middleware() doesn't call process_view() properly
Reported by: | Marty Alchin | Owned by: | Gary Wilson |
---|---|---|---|
Component: | Uncategorized | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
In django.utils.decorators.decorator_from_middleware()
, the portion which calls the middleware's process_view()
method does with the dynamic argument modifies *
and **
, even though the middleware protocol specifies that the args
and kwargs
values should come in as separate distinct arguments.
If this function is used to transform any middleware that implements the process_view()
method into a decorator, a TypeError
is raised when any view using that decorator is executed.
TypeError: process_view() got an unexpected keyword argument '...'
Attachments (1)
Change History (4)
by , 17 years ago
comment:1 by , 17 years ago
Triage Stage: | Unreviewed → Ready for checkin |
---|
comment:3 by , 17 years ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.
Simple fix, removing the argument modifiers so
process_view()
gets called the way it should