Opened 3 years ago

Closed 3 years ago

#18692 closed Bug (fixed)

Django 1.3.2 breaks Python 2.4 compatibility

Reported by: chipx86 Owned by: nobody
Component: HTTP handling Version: 1.3
Severity: Release blocker Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


The recent URL scheme restriction change assumes Python 2.5+ accessors for the parsed URI information. Specifically, it's looking up parsed.scheme, which isn't available in Python 2.4. Instead, it should be accessing it as a tuple.

The traceback below shows what's happening.

Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/Django-1.3.2-py2.4.egg/django/core/handlers/", line 111, in get_response
    response = callback(request, *callback_args, **callback_kwargs)
  File "/usr/lib/python2.4/site-packages/Django-1.3.2-py2.4.egg/django/views/generic/", line 57, in redirect_to
    return klass(url % kwargs)
  File "/usr/lib/python2.4/site-packages/Django-1.3.2-py2.4.egg/django/http/", line 645, in __init__
    if parsed.scheme and parsed.scheme not in self.allowed_schemes:
AttributeError: 'tuple' object has no attribute 'scheme'

Change History (2)

comment:1 Changed 3 years ago by jezdez

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Severity changed from Normal to Release blocker
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 3 years ago by Florian Apolloner <florian@…>

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

In [d0d5dc6cd76f01c8a71b677357ad2f702cb54416]:

[1.3.x] Fixed #18692 -- Restored python 2.4 compatibility.

Thanks to chipx86 for the report.

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