p4dZddlmZddlZddlZddlZddlZddlZddlZddl Z ddl m Z ddl m Z ddl mZddlmZmZmZmZddlmZejeZeezZ ddlZeez Zn #e$red YnwxYw ddlZeez Zn #e$red YnwxYwd/d Zd0dZd1dZ d2dZ!d/dZ"d3dZ#d4dZ$d5d6d#Z%d7d$Z&d8d)Z'd9d+Z( d:d;d.Z)dS)zuntar_file..s"N"N"N66;"N"N"Nrrdtarfile.TarInforrr c|j} |}nB#tj$r0tjdddvrtj|}nYnwxYwn<#tj$r*}d}t||d}~wwxYw| r |dzr|_nd|_|S)N>rh rh rh z%Invalid member in the tar file {}: {}r3) r@tarfileLinkOutsideDestinationErrorsys version_info tar_filterTarErrorrrPisfile) rdr orig_modeexcr[ data_filterdefault_mode_plus_executablerBrCs r pip_filterzuntar_file..pip_filters "K "!,VX!>!>"> " " "+BQB/4&-%7%I%IFF!#F "'   EG,$ ==??'y5'8'">FKK #'FK s2 A>+;+;+D+DV+L+L     " "> 2 2     " "= 1 1     " "6 * * ;     ,x 8 8 8CC!"N"NS^^=M=M"N"N"NOO : 8!-K,M+N+N ( 7"nn..77F+v-O-O*(#y00.6FO% % % % % % % % % N NN8JN 7 7 7 7q D D D !(Hc7 C C C C C Dv  s1"+H0 G8BH08HH0HH00Irtarfile.TarFiletarinforfcLtjtj|j|j}tj|}|dd} ||dS#t$rYdSwxYw)zGCheck if the file pointed to by the symbolic link is in the tar archiverrTF) rrrNrOrXrnormpathreplace getmemberKeyError)rrrs ris_symlink_target_in_tarrsw||BGOOGL997;KLLHw))Hc**H ht uus>B B#"B#rWc|D]J}|j}|rt|d}tj||}t ||s&d}t||||| rt|| rt||s0d}t|||j|j  |||#t$r-}t d||j|Yd}~:d}~wwxYw ||} nA#t&t(f$r-}t d||j|Yd}~d}~wwxYwttj|| Jt-|d5} t/j| | dddn #1swxYwY| ||||jdzrt9|LdS)z/Fallback for Python without tarfile.data_filterrzQThe tar file ({}) has a file ({}) trying to install outside target directory ({})z/In the tar file %s the member %s is invalid: %sNrHr3)rrXr!rrrNr1rrPisdirr issymrr_extract_member Exceptionrr extractfilerrrOrIrRrSrTutimer@r9) rBrCrrWrdrYrr[rzr\r]s rrr s..""8I8I [  *"2&&q)Bw||Hb))"8T22 N0 $GNN8T8$L$LMM M <<>>- I t     \\^^+ I+C88 4(NN8V[&/JJ ##FD1111   EK    __V,,n-   EK    rwt,, - - ->>>dD!! /V"2v... / / / / / / / / / / / / / / / HHJJJ IIfd # # #{U" IB4HHHq8I8IsBD E'"EEE..F,?"F''F,/HH H content_type str | NonecJtj|}|dks@|t st j|r(t|||d dS|dksPtj |s<|ttztzrt||dStd|||t#d|)Nzapplication/zipz.whl)rDzapplication/x-gzipzZCannot unpack file %s (downloaded from %s, content-type: %s); cannot detect archive formatz#Cannot determine archive format of )rrrealpathrrQr rJ is_zipfiler^rr is_tarfilerrr rrcriticalr)rBrCrs r unpack_filerNs& w))H))) >>   $ $^ 4 4 *  h ' ' * 8X83D3DV3L3L/LMMMMMM,,,  h ' ' - >>   $ $^n%D}%T U U - 8X&&&&&  +        Ph P PQQQr)r r )rrr r)r"r#r r$)r*rr+rr r$)rrr r6)r:rr r$)T)rBrrCrrDr$r r6)rBrrCrr r6)rrrrfr r$) rBrrCrrrrWr$r r6)N)rBrrCrrrr r6)*__doc__ __future__rloggingrrRr>rtrrrJcollections.abcrrpip._internal.exceptionsrpip._internal.utils.filetypesrrr r pip._internal.utils.miscr getLogger__name__rSUPPORTED_EXTENSIONSbz2 ImportErrordebuglzmarr!r)r1r5r9rAr^rrrrr4rrrs!!"""""" $$$$$$666666 0/////  8 $ $&60JJJN*000 LL./////01KKKM)111 LL/000001        ####,,,,8888>>>>+++++\]]]]@    BIBIBIBIP $RRRRRRRs$ A))BB BB10B1