ok

Mini Shell

Direktori : /opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/
Upload File :
Current File : //opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyc

�
Bu�_c@s�dZddlZddlmZddlmZddlmZddlm	Z	ddl
mZmZddl
mZdd	lmZer�dd
lmZmZnd�Zed��Zd
efd��YZdS(sHTTP cache implementation.
i����N(tcontextmanager(t	BaseCache(t	FileCache(tResponse(tadjacent_tmp_filetreplace(t
ensure_dir(tMYPY_CHECK_RUNNING(tOptionaltIteratorcCst|dt�S(Nt
from_cache(tgetattrtFalse(tresponse((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyt
is_from_cachesccs'y	dVWnttfk
r"nXdS(svIf we can't access the cache then we can just skip caching and process
    requests as if caching wasn't enabled.
    N(tOSErrortIOError(((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pytsuppressed_cache_errorss	t
SafeFileCachecBs;eZdZd�Zd�Zd�Zd�Zd�ZRS(sw
    A file based cache which is safe to use even when the target directory may
    not be accessible or writable.
    cCs8|dk	std��tt|�j�||_dS(Ns!Cache directory must not be None.(tNonetAssertionErrortsuperRt__init__t	directory(tselfR((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyR*scCs<tj|�}t|d �|g}tjj|j|�S(Ni(RtencodetlisttostpathtjoinR(Rtnamethashedtparts((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyt_get_cache_path0sc	CsE|j|�}t��'t|d��}|j�SWdQXWdQXdS(Ntrb(R!Rtopentread(RtkeyRtf((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pytget9s
c
Csk|j|�}t��Mttjj|��t|��}|j|�WdQXt|j	|�WdQXdS(N(
R!RRRRtdirnameRtwriteRR(RR%tvalueRR&((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pytset@s
cCs0|j|�}t��tj|�WdQXdS(N(R!RRtremove(RR%R((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pytdeleteKs
(t__name__t
__module__t__doc__RR!R'R+R-(((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyR$s					(R0Rt
contextlibRtpip._vendor.cachecontrol.cacheRtpip._vendor.cachecontrol.cachesRtpip._vendor.requests.modelsRtpip._internal.utils.filesystemRRtpip._internal.utils.miscRtpip._internal.utils.typingRttypingRR	RRR(((sL/opt/alt/python36/lib/python3.6/site-packages/pip/_internal/network/cache.pyt<module>s	

Zerion Mini Shell 1.0