Opened 17 years ago

Last modified 13 years ago

#4484 closed

traceback in django/middleware/common.py caused by empty old_url — at Version 3

Reported by: VesselinK Owned by: Jacob
Component: Uncategorized Version:
Severity: Keywords:
Cc: vk01@… 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 (last modified by Malcolm Tredinnick)

Somehow managed to get an exception in django/middleware/common.py - old_url[1] was ''
Patch attached.

Happened in both SVN and 0.96. The patch is against 0.96.

Change History (4)

by VesselinK, 17 years ago

Attachment: django_patch added

patch

comment:1 by VesselinK, 17 years ago

Wow, the bug tracker replaced the two single quotes with italic string formating. The first line of the description should read:

Somehow managed to get an exception in django/middleware/common.py - old_url[1] was an empty string. Patch attached.

comment:2 by Simon G. <dev@…>, 17 years ago

Summary: traceback in django/middleware/common.pytraceback in django/middleware/common.py caused by empty old_url
Triage Stage: UnreviewedReady for checkin
Version: 0.96

Ok - so I'm guessing the traceback is occuring when old_url is empty, raising an IndexError when we try to subscript old_url, whilst .endswith doesn't have this problem?

comment:3 by Malcolm Tredinnick, 17 years ago

Description: modified (diff)

(Fixed description)

I have a feeling this is mentioned in another ticket, too, but I can't find it. The fix here looks correct, so I'm going to apply it. Triagers might want to keep an eye out for the dupe.

Note: See TracTickets for help on using tickets.
Back to Top