mirror of
https://github.com/django/django.git
synced 2025-11-07 07:15:35 +00:00
Refs #27025 -- Removed obsolete sqlite3 transaction management workaround for Python 3.6+.
Obsolete per https://bugs.python.org/issue10740#msg274816.
This commit is contained in:
@@ -173,8 +173,8 @@ class Atomic(ContextDecorator):
|
||||
connection.commit_on_exit = True
|
||||
connection.needs_rollback = False
|
||||
if not connection.get_autocommit():
|
||||
# Some database adapters (namely sqlite3) don't handle
|
||||
# transactions and savepoints properly when autocommit is off.
|
||||
# sqlite3 in Python < 3.6 doesn't handle transactions and
|
||||
# savepoints properly when autocommit is off.
|
||||
# Turning autocommit back on isn't an option; it would trigger
|
||||
# a premature commit. Give up if that happens.
|
||||
if connection.features.autocommits_when_autocommit_is_off:
|
||||
|
||||
Reference in New Issue
Block a user