File: //proc/self/root/usr/lib/python3.9/site-packages/redis/asyncio/__pycache__/utils.cpython-39.pyc
a
��b� � @ s: d dl mZ er d dlmZmZ dd� ZG dd� d�ZdS )� )�
TYPE_CHECKING)�Pipeline�Redisc K s ddl m} |j| fi |��S )z�
Returns an active Redis client generated from the given database URL.
Will attempt to extract the database id from the path url fragment, if
none is provided.
r )r )�redis.asyncio.clientr �from_url)�url�kwargsr � r �7/usr/lib/python3.9/site-packages/redis/asyncio/utils.pyr s r c @ s0 e Zd Zdd�dd�Zdd�dd�Zd d
� ZdS )�pipeliner )� redis_objc C s |� � | _d S �N)r �p)�selfr r r r
�__init__ s zpipeline.__init__r )�returnc � s | j S r
)r )r r r r
�
__aenter__ s zpipeline.__aenter__c � s | j �� I d H | ` d S r
)r Zexecute)r �exc_type� exc_value� tracebackr r r
� __aexit__ s zpipeline.__aexit__N)�__name__�
__module__�__qualname__r r r r r r r
r s r N)�typingr r r r r r r r r r
�<module> s