Code

Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#14027 closed (fixed)

reverse(None) returns an unnamed URL, instead of raising an exception

Reported by: Alex Owned by: nobody
Component: Core (Other) Version: master
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

If your project has an unnamed URL reverse(None) returns the last one, instead of raising an exception as one might expect.

Attachments (2)

django-reverse-none.diff (1.3 KB) - added by Alex 4 years ago.
django-reverse-none.2.diff (1.3 KB) - added by Alex 4 years ago.
Apparently widow'd comments are more important than 79 col zealotry :)

Download all attachments as: .zip

Change History (5)

Changed 4 years ago by Alex

comment:1 Changed 4 years ago by Alex

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted

Changed 4 years ago by Alex

Apparently widow'd comments are more important than 79 col zealotry :)

comment:2 Changed 4 years ago by russellm

  • Resolution set to fixed
  • Status changed from new to closed

(In [13499]) Fixed #14027 -- Ensure that reverse() raises an exception when you try to reverse None. Thanks to Alex for the report and patch.

comment:3 Changed 4 years ago by russellm

(In [13500]) [1.2.X] Fixed #14027 -- Ensure that reverse() raises an exception when you try to reverse None. Thanks to Alex for the report and patch.

Backport of r13499 from trunk.

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.