Just following suit, as found in backends.postgresql_psycopg2.base

This commit is contained in:
Brant Steen
2014-06-24 15:37:36 -04:00
parent 554fe27ef9
commit 4f4f99dff3
2 changed files with 5 additions and 3 deletions
+4 -2
View File
@@ -98,11 +98,13 @@ class DatabaseWrapper(Psycopg2DatabaseWrapper):
def _commit(self):
if self.connection is not None and self.connection.is_valid:
return self.connection.commit()
with self.wrap_database_errors:
return self.connection.commit()
def _rollback(self):
if self.connection is not None and self.connection.is_valid:
return self.connection.rollback()
with self.wrap_database_errors:
return self.connection.rollback()
def _dispose(self):
"""Dispose of the pool for this instance, closing all connections."""
+1 -1
View File
@@ -21,7 +21,7 @@ required = [
setup(
name='django-postgrespool',
version='0.2.5',
version='0.2.6',
description='Postgres Connection Pooling for Django.',
long_description=open('README.rst').read(),
author='Kenneth Reitz',