Opened 18 years ago
Closed 18 years ago
#4044 closed (fixed)
URLconf with prefix and callable views raises an exception
Reported by: | Owned by: | Adrian Holovaty | |
---|---|---|---|
Component: | Core (Other) | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Accepted | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
Despite what the documentation for the URLconf says, having a prefix and callable views results in an exception.
This line here is the reasoning for it. prefix will resolve to True, so it then checks prefix concatenated with the view instead of skipping straight to passing the view. You can't concantenate a string and a function, so an exception is thrown.
Attachments (2)
Change History (5)
comment:1 by , 18 years ago
Summary: | URLconf with prefix and callable views. → URLconf with prefix and callable views raises an exception |
---|---|
Triage Stage: | Unreviewed → Accepted |
by , 18 years ago
Attachment: | url_defaults.patch added |
---|
comment:2 by , 18 years ago
Has patch: | set |
---|
by , 18 years ago
Attachment: | url_defaults.2.patch added |
---|
Improved fix for incorrect handling of non-string views
comment:3 by , 18 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Fix for incorrect handling of non-string views