Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed database backend creation for Python 2.3.

Previously on "things we changed in the recent past".... the database
connection setup was changed. People were happy. Except for those
running on Python 2.3.

We had completely broken Django on Python 2.3. Turns out, this is due to
a long-standing bug in the _threading_local module that interacts with
object creation in 2.3.

Interestingly, although the bug remains in Python 2.4 and 2.5, they
don't trip over it for reasons I don't entirely understand at the

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 19290ed05142372914731a916e14df7c1d02e0d9 1 parent 4e7a4ed
Malcolm Tredinnick authored March 20, 2009

Showing 1 changed file with 2 additions and 2 deletions. Show diff stats Hide diff stats

  1. 4  django/utils/
4  django/utils/
@@ -145,8 +145,8 @@ def __new__(cls, *args, **kw):
145 145
         object.__setattr__(self, '_local__args', (args, kw))
146 146
         object.__setattr__(self, '_local__lock', RLock())
147 147
-        if args or kw and (cls.__init__ is object.__init__):
-            raise TypeError("Initialization arguments are not supported")
+        if (args or kw) and (cls.__init__ is object.__init__):
+            raise TypeError("Initialization arguments are not supported: %r, %r, %r" % (args, kw, cls.__init__ is object.__init__))
150 150
151 151
         # We need to create the thread dict in anticipation of
152 152
         # __init__ being called, to make sure we don't call it

0 notes on commit 19290ed

Please sign in to comment.
Something went wrong with that request. Please try again.