← Back
Editing: transaction.cpython-311.pyc
� �|�e�/ � � � d dl mZmZ d dlmZmZmZmZmZ G d� de� � Z dd�Z dd�Zdd�Zdd �Z dd �Zdd�Zdd�Zdd �Zdd�Zdd�Zdd�Zedd�� � Zdd�Z G d� de� � Zdd�Zd� Zdd�ZdS )� )�ContextDecorator�contextmanager)�DEFAULT_DB_ALIAS� DatabaseError�Error�ProgrammingError�connectionsc � � e Zd ZdZdS )�TransactionManagementErrorz*Transaction management is used improperly.N)�__name__� __module__�__qualname__�__doc__� � �7/usr/lib/python3/dist-packages/django/db/transaction.pyr r s � � � � � �4�4��Dr r Nc �. � | �t } t | S )z� Get a database connection by name, or the default database connection if no name is provided. This is a private API. )r r ��usings r �get_connectionr s � � �}� ���u��r c �D � t | � � � � � S )z,Get the autocommit status of the connection.)r �get_autocommitr s r r r s � ��%� � �/�/�1�1�1r c �F � t |� � � | � � S )z,Set the autocommit status of the connection.)r �set_autocommit)� autocommitr s r r r s � ��%� � �/�/� �;�;�;r c �H � t | � � � � � dS )zCommit a transaction.N)r �commitr s r r r ! s"