+
    j'Ïj€$  ã                   óþ   € ^ RI t ^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RIHtH	t	 ^ RI
Ht ^ RIHt ^ RIHtHtHtHt R tRsRR	0t ! R
 R]4      t]! R. RO4       ! R R]P.                  4      4       t ! R R]4      tR# )é    N)Úsuppress)Úcached_propertyÚwraps)Úparse_qs)ÚAbstractFileSystem)Ú"get_package_version_without_importÚinfer_storage_optionsÚmirror_fromÚtokenizec                 ó0   a € \        S 4      V 3R  l4       pV# )c                  óî   <€  S! V / VB #   \          d_   pTP                  '       g   h TP                  vr0\        T\        4      '       d#   R T9   d   \	        \
        P                  T4      Thh Rp?ii ; i)zdoes not existN)ÚOSErrorÚargsÚ
isinstanceÚstrÚFileNotFoundErrorÚerrnoÚENOENT)r   ÚkwargsÚ	exceptionÚmessageÚfuncs   *,  €ÚV/opt/data/cache/scratch/pip-target-lhm_ju4v/lib/python/fsspec/implementations/arrow.pyÚwrapperÚ wrap_exceptions.<locals>.wrapper   sj   ø€ ð
	Ù˜Ð( Ñ(Ð(øÜô 	Ø—>—>�>Øà&Ÿ^™^ˆNˆGÜ˜'¤3×'Ò'Ð,<ÀÔ,GÜ'¬¯©°gÓ>ÀIÐMàûð	ús   ƒ ‹A4–AA/Á/A4)r   )r   r   s   f r   Úwrap_exceptionsr      s    ø€ Ü
ˆ4ƒ[ôó ðð €Nó    ÚgcsÚs3c                   óN  a a€ ] tR t^)t oRtRtV 3R lt]R 4       t]	R 4       t
V 3R lt]R 4       tRR ltR	 tR
 tR t]R 4       t]R 4       t]R 4       t]RR l4       t]RR l4       t]RR l4       t]RR l4       t]R 4       t]R 4       tRV 3R lltV 3R ltRtVtV ;t # )ÚArrowFSWrapperzgFSSpec-compatible wrapper of pyarrow.fs.FileSystem.

Parameters
----------
fs : pyarrow.fs.FileSystem

Ú/c                ó‚   <€ \        R 4      sWn        VP                  \        9   d   RV n        \        SV `  ! R/ VB  R# )ÚpyarrowÚ N© )r   ÚPYARROW_VERSIONÚfsÚ	type_nameÚ_EMPTY_ROOT_MARKER_FILESYSTEMSÚroot_markerÚsuperÚ__init__)Úselfr(   r   Ú	__class__s   &&,€r   r-   ÚArrowFSWrapper.__init__4   s7   ø€ ä<¸YÓGˆØŒØ�<‰<Ô9Ô9Ø!ˆDÔÜ‰ÒÑ"˜6Ô"r   c                ó.   € V P                   P                  # ©N)r(   r)   ©r.   s   &r   ÚprotocolÚArrowFSWrapper.protocol<   s   € à�w‰w× Ñ Ð r   c                óx   € R \        V P                  P                  V P                  P                  4      ,           # )Úhdfs_)r   r(   ÚhostÚportr3   s   &r   ÚfsidÚArrowFSWrapper.fsid@   s$   € àœ $§'¡'§,¡,°·±·±Ó=Õ=Ð=r   c                óÊ   <€ V P                   '       d   \        SV `	  V4      # V P                  V4      P	                  R 4      pR V9   d   VP                  R ^4      ^ ,          # R# )r"   r%   )r+   r,   Ú_parentÚ_strip_protocolÚlstripÚrsplit)r.   Úpathr/   s   &&€r   r=   ÚArrowFSWrapper._parentD   sZ   ø€ Ø××ÐÜ‘7‘? 4Ó(Ð(à×#Ñ# DÓ)×0Ñ0°Ó5ˆØ),°¬ˆt�{‰{˜3 Ó" 1Õ%Ð<¸"Ð<r   c                ón   € \        V4      pVR ,          pVP                  R4      '       d
   VR,          pV# )rA   z//:é   NN)r	   Ú
startswith)ÚclsrA   Úopss   && r   r>   ÚArrowFSWrapper._strip_protocolK   s2   € ä# DÓ)ˆØ�6�{ˆØ�?‰?˜4× Ò à˜•8ˆDØˆr   c                ó^  € V P                  V4      p^ RIHp  V P                  P	                  V! V4      4       Uu. uF  pV P                  V4      NK  	  ppV'       d   V# V Uu. uF  qUR,          NK  	  up# u upi   \        \        3 d    T P                  ! T3/ TB .p LNi ; iu upi )r   )ÚFileSelectorÚname)	r>   Ú
pyarrow.fsrJ   r(   Úget_file_infoÚ_make_entryr   ÚNotADirectoryErrorÚinfo)r.   rA   Údetailr   rJ   ÚentryÚentriess   &&&,   r   ÚlsÚArrowFSWrapper.lsT   s´   € Ø×#Ñ# DÓ)ˆÝ+ð	2ð "ŸW™W×2Ñ2±<ÀÓ3EÔFóáF�Eð × Ñ  Ö'ÙFð ð ÷ ØˆNá/6Ó7©w e˜&—M�M©wÑ7Ð7ùòøô "Ô#5Ð6ô 	2Ø—y’y Ñ0¨Ñ0Ð1ŠGð	2üò
 8s(   ™#A? ¼A:ÁA? Á&B*Á:A? Á?%B'Â&B'c                ó‚   € V P                  V4      pV P                  P                  V.4      w  pV P                  V4      # r2   )r>   r(   rM   rN   )r.   rA   r   rP   s   &&, r   rP   ÚArrowFSWrapper.infod   s;   € Ø×#Ñ# DÓ)ˆØ—‘×&Ñ&¨ vÓ.‰ˆØ×Ñ Ó%Ð%r   c                óp   € V P                  V4      p V P                  V4       R #   \         d     R# i ; i)TF)r>   rP   r   ©r.   rA   s   &&r   ÚexistsÚArrowFSWrapper.existsi   s;   € Ø×#Ñ# DÓ)ˆð	Ø�I‰I�dŒOñ øô !ô 	Úð	ús   “& ¦5´5c                ó˜  € ^ RI Hp VP                  VP                  J d   RpM€VP                  VP                  J d   RpMcVP                  VP
                  J dH   \        \        P                  \        P                  ! \        P                  4      VP                  4      hRpRVP                  RVP                  RVRVP                  /# )	r   )ÚFileTypeÚ	directoryÚfileÚotherrK   ÚsizeÚtypeÚmtime)rL   r]   rb   Ú	DirectoryÚFileÚNotFoundr   r   r   ÚosÚstrerrorrA   ra   rc   )r.   rP   r]   Úkinds   &&  r   rN   ÚArrowFSWrapper._make_entryr   s˜   € Ý'à�9‰9˜×*Ñ*Ó*Ø‰DØ�Y‰Y˜(Ÿ-™-Ó'Ø‰DØ�Y‰Y˜(×+Ñ+Ó+Ü#¤E§L¡L´"·+²+¼e¿l¹lÓ2KÈTÏYÉYÓWÐWàˆDð �D—I‘IØ�D—I‘IØ�DØ�T—Z‘Zð	
ð 	
r   c           
     ó¸  € V P                  V4      P                  R 4      pV P                  V4      P                  R 4      pV P                  VR4      ;_uu_ 4       pV R\        P                  ! ^4       2p V P                  VR4      ;_uu_ 4       p\        P                  ! WF4       RRR4       V P                  P                  WR4        RRR4       R#   + '       g   i     L6; i  \         dQ    \        \        4      ;_uu_ 4        T P                  P                  T4       RRR4       h   + '       g   i     h ; ii ; i  + '       g   i     R# ; i)r"   Úrbz.tmp.ÚwbN)r>   ÚrstripÚ_openÚsecretsÚ	token_hexÚopenÚshutilÚcopyfileobjr(   ÚmoveÚBaseExceptionr   r   Údelete_file)r.   Úpath1Úpath2r   ÚlstreamÚ	tmp_fnameÚrstreams   &&&,   r   Úcp_fileÚArrowFSWrapper.cp_file…   s  € à×$Ñ$ UÓ+×2Ñ2°3Ó7ˆØ×$Ñ$ UÓ+×2Ñ2°3Ó7ˆà�Z‰Z˜˜t×$Ô$¨Ø ˜' ¤w×'8Ò'8¸Ó';Ð&<Ð=ˆIðØ—Y‘Y˜y¨$×/Ô/°7Ü×&Ò& wÔ8÷ 0à—‘—‘˜YÕ.÷ %Ñ$÷ 0×/ûô !ô ÜÔ/×0Õ0Ø—G‘G×'Ñ'¨	Ô2÷ 1à÷ 1Ö0àúðú÷ %×$Ð$úsN   ÁEÁ8C*ÂC	Â)#C*ÃC'Ã"C*Ã*"EÄD1Ä(	EÄ1EÄ<	EÅEÅE	c                ó¼   € V P                  V4      P                  R 4      pV P                  V4      P                  R 4      pV P                  P                  W4       R# )r"   N)r>   rn   r(   ru   )r.   rx   ry   r   s   &&&,r   ÚmvÚArrowFSWrapper.mv•   sH   € à×$Ñ$ UÓ+×2Ñ2°3Ó7ˆØ×$Ñ$ UÓ+×2Ñ2°3Ó7ˆØ�‰�‰�UÖ"r   c                ó^   € V P                  V4      pV P                  P                  V4       R # r2   )r>   r(   rw   rY   s   &&r   Úrm_fileÚArrowFSWrapper.rm_file›   s$   € à×#Ñ# DÓ)ˆØ�‰×Ñ˜DÖ!r   c                ó
  € V P                  V4      P                  R 4      pV P                  V4      '       d1   V'       d   V P                  P	                  V4       R# \        R4      hV P                  P                  V4       R# )r"   z0Can't delete directories without recursive=FalseN)r>   rn   Úisdirr(   Ú
delete_dirÚ
ValueErrorrw   )r.   rA   Ú	recursiveÚmaxdepths   &&&&r   ÚrmÚArrowFSWrapper.rm    s_   € à×#Ñ# DÓ)×0Ñ0°Ó5ˆØ�:‰:�d×ÒßØ—‘×"Ñ" 4Ö(ä Ð!SÓTÐTà�G‰G×Ñ Ö%r   c                óÀ  € VR 8X  d7   V'       d   V P                   P                  pMbV P                   P                  pMKVR8X  d   V P                   P                  pM-VR8X  d   V P                   P                  pM\        RV: 24      h/ pVR 8w  g	   V'       g0   \        \        P                  R4      ^ ,          4      ^8¼  d   RVR&   V! V3/ VB p\        WWV3/ VB # )rl   rm   Úabz'unsupported mode for Arrow filesystem: Ú.NÚcompression)
r(   Úopen_input_fileÚopen_input_streamÚopen_output_streamÚopen_append_streamrˆ   Úintr'   ÚsplitÚ	ArrowFile)	r.   rA   ÚmodeÚ
block_sizeÚseekabler   ÚmethodÚ_kwargsÚstreams	   &&&&&,   r   ro   ÚArrowFSWrapper._open«   sÁ   € à�4Œ<ßØŸ™×0Ñ0‘àŸ™×2Ñ2‘Ø�TŒ\Ø—W‘W×/Ñ/‰FØ�TŒ\Ø—W‘W×/Ñ/‰FäÐFÀtÁhÐOÓPÐPàˆØ�4Œ<ŸxÜ”?×(Ñ(¨Ó-¨aÕ0Ó1°QÔ6à)-�˜Ñ&Ù˜Ñ( Ñ(ˆä˜ t°:ÑHÀÑHÐHr   c                óœ   € V P                  V4      pV'       d   V P                  VR R7       R# V P                  P                  VRR7       R# )T)Úexist_okF©r‰   N)r>   Úmakedirsr(   Ú
create_dir)r.   rA   Úcreate_parentsr   s   &&&,r   ÚmkdirÚArrowFSWrapper.mkdirÂ   s<   € à×#Ñ# DÓ)ˆßØ�M‰M˜$¨ˆMÖ.à�G‰G×Ñ˜t¨uÐÖ5r   c                ób   € V P                  V4      pV P                  P                  VR R7       R# )Tr¡   N)r>   r(   r£   )r.   rA   r    s   &&&r   r¢   ÚArrowFSWrapper.makedirsÊ   s)   € à×#Ñ# DÓ)ˆØ�‰×Ñ˜4¨4ÐÖ0r   c                ó^   € V P                  V4      pV P                  P                  V4       R # r2   )r>   r(   r‡   rY   s   &&r   ÚrmdirÚArrowFSWrapper.rmdirÏ   s$   € à×#Ñ# DÓ)ˆØ�‰×Ñ˜4Ö r   c                ón   € V P                  V4      pV P                  P                  V4      P                  # r2   )r>   r(   rM   rc   rY   s   &&r   ÚmodifiedÚArrowFSWrapper.modifiedÔ   s-   € à×#Ñ# DÓ)ˆØ�w‰w×$Ñ$ TÓ*×0Ñ0Ð0r   c                óR   <€ VP                  R VR9  4       \        SV `  ! WV3/ VB # )rš   )Nr   )Ú
setdefaultr,   Úcat_file)r.   rA   ÚstartÚendr   r/   s   &&&&,€r   r±   ÚArrowFSWrapper.cat_fileÙ   s/   ø€ Ø×Ñ˜* e°9Ñ&<Ô=Ü‰wÒ ¨SÑ;°FÑ;Ð;r   c                óN   <€ VP                  R R4       \        SV `  ! W3/ VB  R# )rš   FN)r°   r,   Úget_file)r.   ÚrpathÚlpathr   r/   s   &&&,€r   r¶   ÚArrowFSWrapper.get_fileÝ   s%   ø€ Ø×Ñ˜* eÔ,Ü‰Ò˜Ñ0¨Ô0r   )r(   r+   )F)FN)rl   NT)T)NN)!Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r+   r-   Úpropertyr4   r   r:   r=   Úclassmethodr>   rT   rP   rZ   rN   r   r}   r€   rƒ   r‹   ro   r¥   r¢   rª   r­   r±   r¶   Ú__static_attributes__Ú__classdictcell__Ú__classcell__©r/   Ú__classdict__s   @@r   r!   r!   )   s0  ù‡ € ñð €Kõ#ð ñ!ó ð!ð ñ>ó ð>õ=ð ñó ðô8ò &ò
ò
ð& ñó ðð ñ#ó ð#ð
 ñ"ó ð"ð ó&ó ð&ð óIó ðIð, ó6ó ð6ð ó1ó ð1ð ñ!ó ð!ð ñ1ó ð1÷<÷1õ 1r   r!   r�   c                   óV   a € ] tR t^ât o RR ltR t]R 4       t]R 4       tR t	Rt
V tR# )	r—   Nc                ó^   € W0n         W@n        Wn        W n        V;V n        V n        W`n        R # r2   )rA   r˜   r(   r�   Ú	blocksizer™   r   )r.   r(   r�   rA   r˜   r™   r   s   &&&&&&,r   r-   ÚArrowFile.__init__ò   s)   € ØŒ	ØŒ	àŒØŒà+5Ð5ˆŒ˜œØŽr   c                ó   € V # r2   r&   r3   s   &r   Ú	__enter__ÚArrowFile.__enter__ü   s   € Øˆr   c                ó.   € V P                   P                  # r2   )r�   Úclosedr3   s   &r   rÎ   ÚArrowFile.closedÿ   s   € à�{‰{×!Ñ!Ð!r   c                óz   € V P                   P                  4       '       d   V P                   P                  4       # R # r2   )r�   rš   ra   r3   s   &r   ra   ÚArrowFile.size  s+   € à�;‰;×Ñ×!Ò!Ø—;‘;×#Ñ#Ó%Ð%Ùr   c                ó"   € V P                  4       # r2   )Úclose)r.   r   s   &*r   Ú__exit__ÚArrowFile.__exit__	  s   € Ø�z‰z‹|Ðr   )r™   rÈ   r(   r   r˜   rA   r�   r2   )rº   r»   r¼   r½   r-   rË   r¿   rÎ   ra   rÔ   rÁ   rÂ   )rÅ   s   @r   r—   r—   â   sA   ø‡ € ô òð ñ"ó ð"ð ñó ð÷
ð r   r—   c                   óN   a a€ ] tR tRt oRtRtRV 3R llt]R 4       tRt	Vt
V ;t# )ÚHadoopFileSystemi  zYA wrapper on top of the pyarrow.fs.HadoopFileSystem
to connect it's interface with fsspecÚhdfsc           	     óT   <€ ^ RI Hp V! VVVVVVR7      p	\        S
V `  ! RRV	/VB  R# )aÃ  

Parameters
----------
host: str
    Hostname, IP or "default" to try to read from Hadoop config
port: int
    Port to connect on, or default from Hadoop config if 0
user: str or None
    If given, connect as this username
kerb_ticket: str or None
    If given, use this ticket for authentication
replication: int
    set replication factor of file for write operations. default value is 3.
extra_conf: None or dict
    Passed on to HadoopFileSystem
)r×   )r8   r9   ÚuserÚkerb_ticketÚreplicationÚ
extra_confr(   Nr&   )rL   r×   r,   r-   )r.   r8   r9   rÚ   rÛ   rÜ   rÝ   r   r×   r(   r/   s   &&&&&&&,  €r   r-   ÚHadoopFileSystem.__init__  s;   ø€ õ6 	0áØØØØ#Ø#Ø!ô
ˆô 	‰ÒÑ)˜BÐ) &Ô)r   c                ó´  € \        V 4      p/ pVP                  R R4      '       d   VR ,          VR &   VP                  RR4      '       d   VR,          VR&   VP                  RR4      '       d   VR,          VR&   VP                  RR4      '       dG   \        VR,          4      pVP                  RR4      '       d   \        VR,          ^ ,          4      VR&   V# )r8   NÚusernamerÚ   r9   Ú	url_queryrÜ   )r	   Úgetr   r•   )rA   rG   ÚoutÚqueriess   &   r   Ú_get_kwargs_from_urlsÚ&HadoopFileSystem._get_kwargs_from_urls:  sº   € ä# DÓ)ˆØˆØ�7‰7�6˜4× Ò Ø˜f�+ˆC�‰KØ�7‰7�:˜t×$Ò$Ø˜j�/ˆC�‰KØ�7‰7�6˜4× Ò Ø˜f�+ˆC�‰KØ�7‰7�; ×%Ò%Ü˜s ;Õ/Ó0ˆGØ�{‰{˜=¨$×/Ò/Ü%(¨°Õ)?ÀÕ)BÓ%C��MÑ"Øˆ
r   r&   )Údefaultr   NNé   N)rº   r»   r¼   r½   r¾   r4   r-   Ústaticmethodrå   rÁ   rÂ   rÃ   rÄ   s   @@r   r×   r×     s0   ù‡ € ñ-ð €H÷%*ðN ñó ÷ð r   r×   )
ÚreadÚreadintoÚseekÚtellÚwriteÚflushÚreadableÚwritablerÓ   rš   )r   Úiorg   rp   rs   Ú
contextlibr   Ú	functoolsr   r   Úurllib.parser   Úfsspec.specr   Úfsspec.utilsr   r	   r
   r   r   r'   r*   r!   ÚIOBaser—   r×   r&   r   r   Ú<module>rù      sˆ   ðÛ Û 	Û 	Û Û Ý ß ,Ý !å *÷ó òð$ €Ø"'¨ Ð ôv1Ð'ô v1ñr Øòóô�—	‘	ó óðô8;�~ö ;r   