mirror of
https://github.com/django/django.git
synced 2025-09-15 06:55:32 +00:00
Fixed #13798 -- Added connection argument to the connection_created signal. Thanks to liangent for the report, and Alex Gaynor for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@13672 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
a5c80a28dc
commit
6909c22663
8 changed files with 35 additions and 45 deletions
|
@ -135,8 +135,9 @@ class DatabaseWrapper(BaseDatabaseWrapper):
|
|||
if settings_dict['PORT']:
|
||||
conn_string += " port=%s" % settings_dict['PORT']
|
||||
self.connection = Database.connect(conn_string, **settings_dict['OPTIONS'])
|
||||
self.connection.set_isolation_level(1) # make transactions transparent to all cursors
|
||||
connection_created.send(sender=self.__class__)
|
||||
# make transactions transparent to all cursors
|
||||
self.connection.set_isolation_level(1)
|
||||
connection_created.send(sender=self.__class__, connection=self)
|
||||
cursor = self.connection.cursor()
|
||||
if new_connection:
|
||||
if set_tz:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue