
    Wh                    f   d dl mZ d dlZd dlZd dlZd dlZd dlmZ d dlm	Z	 d dl
mZ d dlZd dlmZ d dlmZ d dlmZ d d	lmZ d d
lmZ d dlmZ d dlmZ d dlmZ d dlm Z  d dl!m"Z" d dl#m$Z$  ej%        e&          Z'd+dZ(d,dZ)d-dZ*d.dZ+d/dZ,d0d!Z-d,d"Z.d1d%Z/d2d(Z0 G d) d*e          Z1dS )3    )annotationsN)Values)
ModuleType)Any)where)parse)
cmdoptions)Command)make_target_python)SUCCESS)Configuration)get_environment)open_text_resource)
indent_log)get_pip_versionnamestrvaluer   returnNonec                >    t                               d| |           d S )Nz%s: %s)loggerinfo)r   r   s     n/var/www/tools.fuzzalab.pt/emblema-extractor/venv/lib/python3.11/site-packages/pip/_internal/commands/debug.py
show_valuer      s    
KK$&&&&&    c                     t                               d           t          j        j        } t                      5  t          d|            d d d            d S # 1 swxY w Y   d S )Nzsys.implementation:r   )r   r   sysimplementationr   r   r   )implementation_names    r   show_sys_implementationr!       s    
KK%&&&,1	 0 06.///0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0s   AAAdict[str, str]c                     t          dd          5 } d |                                 D             }d d d            n# 1 swxY w Y   t          d |D                       S )Nzpip._vendorz
vendor.txtc                r    g | ]4}d |v |                                                     dd          d         5S )==    r   )stripsplit.0lines     r   
<listcomp>z)create_vendor_txt_map.<locals>.<listcomp>+   sA     
 
 
.2tt||DJJLLsA&&q)|||r   c              3  B   K   | ]}|                     d d          V  dS )r%   r'   Nr)   r*   s     r   	<genexpr>z(create_vendor_txt_map.<locals>.<genexpr>0   s0      66

4##666666r   )r   	readlinesdict)fliness     r   create_vendor_txt_mapr5   '   s    	M<	8	8 
A
 
67kkmm
 
 

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 66666666s   <A A module_nameModuleType | Nonec                D   |                                                      dd          } | dk    rd} 	 t          d|  t                      t	                      d           t          t          j        |           S # t          $ r | dk    rt          j
        d	k     rY d S  w xY w)
N-_
setuptoolspkg_resourceszpip._vendor.r   )level
truststore)   
   )lowerreplace
__import__globalslocalsgetattrpip_vendorImportErrorr   version_info)r6   s    r   get_module_from_module_namerK   3   s    ##%%--c377Kl""%/+//FHHANNNNs{K000    ,&&3+;g+E+E44s   AA: : BB
str | Nonec                   t          |           }t          |dd           }|rh|sf|j        J t          t          j                            |j                  g          }|                    |           }|rt          |j	                  }|S )N__version__)
rK   rF   __file__r   ospathdirnameget_distributionr   version)r6   modulerT   envdists        r   get_vendor_version_from_modulerX   E   s    (55FfmT22G (g (***rwv??@AA##K00 	($,''GNr   vendor_txt_versionsc                    |                                  D ]`\  }}d}t          |          }|sd}|}n&t          |          t          |          k    rd| d}t                              d|||           adS )z{Log the actual version and print extra info if there is
    a conflict or if the actual version could not be imported.
     zM (Unable to locate actual module version, using vendor.txt specified version)z2 (CONFLICT: vendor.txt suggests version should be )z%s==%s%sN)itemsrX   parse_versionr   r   )rY   r6   expected_versionextra_messageactual_versions        r   show_actual_vendor_versionsrb   T   s     *=)B)B)D)D L L%%7DD 
	1  .NN>**m<L.M.MMM+'+ + +  	J^]KKKKL Lr   c                     t                               d           t                      } t                      5  t	          |            d d d            d S # 1 swxY w Y   d S )Nzvendored library versions:)r   r   r5   r   rb   )rY   s    r   show_vendor_versionsrd   i   s    
KK,---/11	 9 9#$78889 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9s   AAAoptionsr   c                ,   d}t          |           }|                                }|                                }d}|rd| d}dt          |           | }t                              |           | j        dk     r t          |          |k    rd}|d |         }nd}t                      5  |D ])}t                              t          |                     *|r d	| d
}t                              |           d d d            d S # 1 swxY w Y   d S )Nr@   r[   z
 (target: r\   zCompatible tags: r'   TFz...
[First z) tags shown. Pass --verbose to show all.])	r   get_sorted_tagsformat_givenlenr   r   verboser   r   )	re   	tag_limittarget_pythontagsformatted_targetsuffixmsgtags_limitedtags	            r   	show_tagsrs   q   sz   I&w//M((**D %1133F 21.111
1c$ii
1
1
1C
KKs4yy944JYJ	   	" 	"CKKC!!!! 	UUUUCKK                 s   -AD		DDconfigr   c                    d |                                  D             }|sdS g dfd|D             }|sdS d|v r|                    d           d                    |          S )Nc                L    h | ]!\  }}|                     d d          d         "S ).r'   r   r/   )r+   keyr:   s      r   	<setcomp>z!ca_bundle_info.<locals>.<setcomp>   s/    @@@vsAciiQ"@@@r   zNot specified)installwheeldownloadc                    g | ]}|v |	S  r~   )r+   r=   levels_that_override_globals     r   r-   z"ca_bundle_info.<locals>.<listcomp>   s+       U.I%I%I%I%I%Ir   globalz, )r]   removejoin)rt   levelsglobal_overriding_levelr   s      @r   ca_bundle_infor      s    @@@@@F "B"B"B   !   # x6h99Vr   c                  *    e Zd ZdZdZdZddZddZdS )DebugCommandz$
    Display debug information.
    z
      %prog <options>Tr   r   c                    t          j        | j                   | j                            d| j                   | j        j                                         d S )Nr   )r	   add_target_python_optionscmd_optsparserinsert_option_grouprt   load)selfs    r   add_optionszDebugCommand.add_options   sL    ,T];;;''4=999!!!!!r   re   r   args	list[str]intc                   t                               d           t          dt                                 t          dt          j                   t          dt          j                   t          dt	          j                               t          dt	          j                               t          dt          j
                               t          dt          j                   t                       t          d	t          | j        j                             t          d
t           j                            d
                     t          dt           j                            d                     t          dt'                                 t          dt(          j        j                   t/                       t1          |           t2          S )NzThis command is only meant for debugging. Do not use this with automation for parsing and getting these details, since the output and options of this command may change without notice.zpip versionzsys.versionzsys.executablezsys.getdefaultencodingzsys.getfilesystemencodingzlocale.getpreferredencodingzsys.platformz'cert' config valueREQUESTS_CA_BUNDLECURL_CA_BUNDLEzpip._vendor.certifi.where()zpip._vendor.DEBUNDLED)r   warningr   r   r   rT   
executablegetdefaultencodinggetfilesystemencodinglocalegetpreferredencodingplatformr!   r   r   rt   rP   environgetr   rG   rH   	DEBUNDLEDrd   rs   r   )r   re   r   s      r   runzDebugCommand.run   sw   %	
 	
 	
 	=/"3"3444=#+...#S^444+S-C-E-EFFF.0I0K0KLLL)'))	
 	
 	
 	>3<000!!!(.9K*L*LMMM'8L)M)MNNN#RZ^^4D%E%EFFF0%'':::*CK,ABBB'r   Nr   r   )re   r   r   r   r   r   )__name__
__module____qualname____doc__usageignore_require_venvr   r   r~   r   r   r   r      sS         E" " " "
     r   r   )r   r   r   r   r   r   r   )r   r"   )r6   r   r   r7   )r6   r   r   rL   )rY   r"   r   r   )re   r   r   r   )rt   r   r   r   )2
__future__r   r   loggingrP   r   optparser   typesr   typingr   pip._vendorrG   pip._vendor.certifir   pip._vendor.packaging.versionr   r^   pip._internal.clir	   pip._internal.cli.base_commandr
   pip._internal.cli.cmdoptionsr   pip._internal.cli.status_codesr   pip._internal.configurationr   pip._internal.metadatar   pip._internal.utils.compatr   pip._internal.utils.loggingr   pip._internal.utils.miscr   	getLoggerr   r   r   r!   r5   rK   rX   rb   rd   rs   r   r   r~   r   r   <module>r      sA   " " " " " "   				 



                       % % % % % % @ @ @ @ @ @ ( ( ( ( ( ( 2 2 2 2 2 2 ; ; ; ; ; ; 2 2 2 2 2 2 5 5 5 5 5 5 2 2 2 2 2 2 9 9 9 9 9 9 2 2 2 2 2 2 4 4 4 4 4 4		8	$	$' ' ' '0 0 0 0	7 	7 	7 	7   $   L L L L*9 9 9 9   <   "+ + + + +7 + + + + +r   