o
    Ëý°j\  ã                   @   sz   d Z ddlZddlZddlZg d¢Ze e¡Zdefdd„Z	de
defdd	„Zh d
£Zej d¡p:ejdko:ejdkZdS )zKStuff that differs in different Python versions and platform
distributions.é    N)Úget_path_uidÚstdlib_pkgsÚWINDOWSÚreturnc                  C   s2   zdd l } W dS  ty   Y nw ddlm} |S )Nr   T)ÚIS_PYOPENSSL)Ú_sslÚImportErrorÚpip._vendor.urllib3.utilr   )r   r   © r
   ú�/root/aizidognhua/tmp/workspace/projects/ec89d86c-575f-41c9-af57-ac45cbdbf775/venv/lib/python3.10/site-packages/pip/_internal/utils/compat.pyÚhas_tls   s   ÿr   Úpathc                 C   sb   t tdƒrt | tjtjB ¡}t |¡j}t |¡ |S tj 	| ¡s*t 
| ¡j}|S t| › d�ƒ‚)a)  
    Return path's uid.

    Does not follow symlinks:
        https://github.com/pypa/pip/pull/935#discussion_r5307003

    Placed this function in compat due to differences on AIX and
    Jython, that should eventually go away.

    :raises OSError: When path is a symlink or can't be read.
    Ú
O_NOFOLLOWz/ is a symlink; Will not return uid for symlinks)ÚhasattrÚosÚopenÚO_RDONLYr   ÚfstatÚst_uidÚcloser   ÚislinkÚstatÚOSError)r   ÚfdÚfile_uidr
   r
   r   r      s   

	úÿr   >   ÚpythonÚwsgirefÚargparseÚwinÚcliÚnt)Ú__doc__Úloggingr   ÚsysÚ__all__Ú	getLoggerÚ__name__ÚloggerÚboolr   ÚstrÚintr   r   ÚplatformÚ
startswithÚnamer   r
   r
   r
   r   Ú<module>   s    
 $