summaryrefslogtreecommitdiff
path: root/django/db/backends/sqlite3/base.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/db/backends/sqlite3/base.py')
-rw-r--r--django/db/backends/sqlite3/base.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/django/db/backends/sqlite3/base.py b/django/db/backends/sqlite3/base.py
index 96b03149d7..a219178570 100644
--- a/django/db/backends/sqlite3/base.py
+++ b/django/db/backends/sqlite3/base.py
@@ -387,7 +387,8 @@ class DatabaseWrapper(BaseDatabaseWrapper):
level = ''
# 'isolation_level' is a misleading API.
# SQLite always runs at the SERIALIZABLE isolation level.
- self.connection.isolation_level = level
+ with self.wrap_database_errors:
+ self.connection.isolation_level = level
def check_constraints(self, table_names=None):
"""