Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.12/site-packages/pip/_internal/commands/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.12/site-packages/pip/_internal/commands/__pycache__/install.cpython-312.pyc

�

4Μg�r��j�ddlZddlZddlZddlZddlZddlZddlmZmZddl	m
Z
mZddlm
Z
ddlmZddlmZddlmZddlmZdd	lmZmZdd
lmZmZddlmZmZddlm Z dd
l!m"Z"ddl#m$Z$ddl%m&Z&ddl'm(Z(m)Z)ddl*m+Z+ddl,m-Z-m.Z.ddl/m0Z0ddl1m2Z2ddl3m4Z4ddl5m6Z6m7Z7m8Z8m9Z9m:Z:m;Z;ddl<m=Z=ddl>m?Z?m@Z@ddlAmBZBmCZCe4eD�ZEGd�de�ZF					d.deGdeeHdeeHdeGd eeHd!e
eHfd"�ZIdeeHdeGd!eGfd#�ZJ				d/d$eeGd%eeHd&eeHd'eeHd(eGd!eGfd)�ZKd*eLd+eGd,eGd!eHfd-�ZMy)0�N)�
SUPPRESS_HELP�Values)�List�Optional)�canonicalize_name)�
print_json)�
WheelCache)�
cmdoptions)�make_target_python)�RequirementCommand�with_cleanup)�ERROR�SUCCESS)�CommandError�InstallationError)�
get_scheme)�get_environment)�InstallationReport)�get_build_tracker)�ConflictDetails�check_install_conflicts)�install_given_reqs)�InstallRequirement�check_legacy_setup_py_options)�WINDOWS��test_writable_dir)�	getLogger)�check_externally_managed�
ensure_dir�get_pip_version�(protect_pip_from_modification_on_windows�warn_if_run_as_root�write_output)�
TempDirectory)�running_under_virtualenv�virtualenv_no_global)�build� should_build_for_install_commandc��eZdZdZdZdd�Zededee	de
fd��Zd	e	d
ede
ddfd�Zd
eedeefd�Zdede	ddfd�Zy)�InstallCommandaI
    Install packages from:

    - PyPI (and other indexes) using requirement specifiers.
    - VCS project urls.
    - Local project directories.
    - Local or remote source archives.

    pip also supports installing from "requirements files", which provide
    an easy way to specify a whole environment to be installed.
    a%
      %prog [options] <requirement specifier> [package-index-options] ...
      %prog [options] -r <requirements file> [package-index-options] ...
      %prog [options] [-e] <vcs project url> ...
      %prog [options] [-e] <local project path> ...
      %prog [options] <archive url/path> ...�returnNc���|jjtj��|jjtj��|jjtj
��|jjtj��|jjtj��|jjddddd��|jjddd	d
dd��tj|j�|jjd
ddd��|jjdddt��|jjddd
dd��|jjddd
dd��|jjtj��|jjddddd��|jjddddd gd!�"�|jjd#d$dd%��|jjd&d'd(dd)��|jjtj��|jjtj��|jjtj��|jjtj��|jjtj��|jjtj ��|jjtj"��|jjtj$��|jjd*dd+d,d-��|jjd.dd+d/�0�|jjd1dd2d,d3��|jjd4dd5d,d6��|jjtj&��|jjtj(��|jjtj*��|jjtj,��|jjtj.��|jjtj0��tj2tj4|j6�}|j6j9d7|�|j6j9d7|j�|jjd8d9d:dd;��y)<Nz	--dry-run�
store_true�dry_runFz�Don't actually install anything, just print what would be. Can be used in combination with --ignore-installed to 'resolve' the requirements.)�action�dest�default�helpz-tz--target�
target_dir�dirz�Install packages into <dir>. By default this will not replace existing files/folders in <dir>. Use --upgrade to replace existing packages in <dir> with new versions.)r1�metavarr2r3z--user�
use_user_sitez�Install to the Python user install directory for your platform. Typically ~/.local/, or %APPDATA%\Python on Windows. (See the Python documentation for site.USER_BASE for full details.))r1r0r3z	--no-user�store_falsez--root�	root_pathz=Install everything relative to this alternate root directory.z--prefix�prefix_patha[Installation prefix where lib, bin and other top-level folders are placed. Note that the resulting installation may contain scripts and other resources which reference the Python interpreter of pip, and not that of ``--prefix``. See also the ``--python`` option if the intention is to install packages into another (possibly pip-free) environment.z-Uz	--upgrade�upgradez�Upgrade all specified packages to the newest available version. The handling of dependencies depends on the upgrade-strategy used.z--upgrade-strategy�upgrade_strategyzonly-if-needed�eageraGDetermines how dependency upgrading should be handled [default: %default]. "eager" - dependencies are upgraded regardless of whether the currently installed version satisfies the requirements of the upgraded package(s). "only-if-needed" -  are upgraded only when they do not satisfy the requirements of the upgraded package(s).)r1r2�choicesr3z--force-reinstall�force_reinstallz;Reinstall all packages even if they are already up-to-date.z-Iz--ignore-installed�ignore_installedz�Ignore the installed packages, overwriting them. This can break your system if the existing package is of a different version or was installed with a different package manager!z	--compile�compileTz'Compile Python source files to bytecodez--no-compilez.Do not compile Python source files to bytecode)r0r1r3z--no-warn-script-location�warn_script_locationz0Do not warn when installing scripts outside PATHz--no-warn-conflicts�warn_about_conflictsz%Do not warn about broken dependenciesrz--report�json_report_file�fileaWGenerate a JSON file describing what pip did to install the provided requirements. Can be used in combination with --dry-run and --ignore-installed to 'resolve' the requirements. When - is used as file name it writes to stdout. When writing to stdout, please combine with the --quiet option to avoid mixing pip logging output with JSON output.)�cmd_opts�
add_optionr
�requirements�constraints�no_deps�pre�editable�add_target_python_optionsr�src�ignore_requires_python�no_build_isolation�
use_pep517�
no_use_pep517�check_build_deps�override_externally_managed�config_settings�global_options�	no_binary�only_binary�
prefer_binary�require_hashes�progress_bar�root_user_action�make_option_group�index_group�parser�insert_option_group)�self�
index_optss  �I/usr/local/lib/python3.12/site-packages/pip/_internal/commands/install.py�add_optionszInstallCommand.add_optionsIs����
�
� � ��!8�!8�!:�;��
�
� � ��!7�!7�!9�:��
�
� � ��!3�!3�!5�6��
�
� � ����!1�2��
�
� � ��!4�!4�!6�7��
�
� � �����1�
	!�
	
�	
�
�
� � ������%�	!�	
�	�,�,�T�]�]�;��
�
� � �� ��%�	!�
	
�	
�
�
� � �� � ��		!�	
�	
�
�
� � �����P�	!�	
�	
�
�
� � ������
	!�	
� 	
�
�
� � ����!1�2��
�
� � �����)�
	!�
	
�	
�
�
� � � �#�$�%�w�/�G�
	!�	
� 	
�
�
� � ��"��N�		!�	
�	
�
�
� � �� �#��4�
	!�	
�	
�
�
� � ��!B�!B�!D�E��
�
� � ��!>�!>�!@�A��
�
� � ��!6�!6�!8�9��
�
� � ��!9�!9�!;�<��
�
� � ��!<�!<�!>�?��
�
� � ��!G�!G�!I�J��
�
� � ��!;�!;�!=�>��
�
� � ��!:�!:�!<�=��
�
� � �����:�	!�	
�	
�
�
� � �� ��A�		!�	
�	
�
�
� � �'� �'��C�	!�	
�	
�
�
� � �!� �'��8�	!�	
�	
�
�
� � ��!5�!5�!7�8��
�
� � ��!7�!7�!9�:��
�
� � ��!9�!9�!;�<��
�
� � ��!:�!:�!<�=��
�
� � ��!8�!8�!:�;��
�
� � ��!<�!<�!>�?��1�1��"�"��K�K�
�
�
	
���'�'��:�6����'�'��4�=�=�9��
�
� � ��#���G�
	!�	
��options�argsc
��|jr|j�td��|jxr|jxr.|j
duxr|jduxr|jdu}|r|js
t�d}|jr|j}tj|d��tjdt��t!|j|j|j|j
|j"��|_d}d}|jr�d|_t&j(j+|j�|_t&j(j-|j�r4t&j(j/|j�std��t1d�	�}|j(}|j3|�|j4xsg}|j7|�}t9|�}	|j;|||	|j<�
�}
|j3t?��}t1|j@dd��}	|jC|||
|�}
tE||
�tG|jH�}|
D]	}d|_%�|jM|||||
|j|jN�
�}|jQ||
|||j|j$|j<|jR||jT|jV��}|jY|
�|j[|
|j��}|jr�t]|j^�}|jdk(rta|jc���nHte|jdd��5}tgjh|jc�|dd��ddd�|jrFtkd�|j^D��}|r"tmddjod�|D���tpS	|jsd�}|jtdu}|rddl;}	t{|��|j|j�D�cgc]}t�|�r|��}}t�||dg|��\}}|r0t�d j�d!jod"�|D�����|j�|�}d}|j�xr|j�}|r|j�|�}|j�} |js|jrd} t�|||j
||j| |j|j��#�}!t�|j||j
|j|j"�$�}"t�|"�}#|!j�t�j�d%��&�g}$i}%|#j��D]}&|&j�|%|&j�<�|!D]F}'|'j�}(|%j�t�|(�d�})|)r|(�d|)��}*n|(}*|$j�|*��H|�"|j�||j�|��'�djo|$�}+|+rtmd(|+�|jr+|sJ�|j�|j||j�|j�d+k(r
t��tpS#1swY��&xYw#tx$rd}Y���wxYwcc}w#t�$rM},|jNd)k\}-t�|,|-|j�}.tj�|.|-�*�t�cYd},~,Sd},~,wwxYw),Nz'Can not combine '--user' and '--target'zto-satisfy-onlyT)�check_targetzUsing %s)r:r4r9�
isolated_modez=Target path exists but is not a directory, will not continue.�target)�kind)rf�session�
target_pythonrO�install)�deleterl�globally_managed)�temp_build_dirrf�
build_trackerrm�finderr7�	verbosity)�preparerrtrf�wheel_cacher7r@rOr?r<rQ�py_version_info)�check_supported_wheels�-)�data�wzutf-8)�encoding�F)�indent�ensure_asciic3�XK�|]"}|jd|jdf���$y�w)�name�versionN)�metadata��.0�rs  rc�	<genexpr>z%InstallCommand.run.<locals>.<genexpr>�s/����-�D���Z�Z��'����I�)>�?�D�s�(*zWould install %s� c3�>K�|]}dj|����y�w)rzN)�join)r��items  rcr�z%InstallCommand.run.<locals>.<genexpr>�s���� P�<O�D����$��<O�s��pipr)�
modifying_pip)rw�verify�
build_optionsrVzUERROR: Failed to build installable wheels for some pyproject.toml based projects ({})z, c3�4K�|]}|j���y�w�N)r�r�s  rcr�z%InstallCommand.run.<locals>.<genexpr>�s����!A�.�Q�!�&�&�.�s�)�root�home�prefixrBr7�	pycompile)�userr�r�r��isolatedr�)�key)�resolver_variantzSuccessfully installed %s�)�exc_info�warn)`r7r4rr/rDr9r:rTrr;r<r
�check_dist_restriction�logger�verboser!�decide_user_installrjr@�os�path�abspath�exists�isdirr%�
enter_contextrV�get_default_sessionr�_build_package_finderrOr�no_clean�get_requirementsrr	�	cache_dir�permit_editable_wheels�make_requirement_preparerru�
make_resolverr?rQ�python_version�trace_basic_info�resolver�requirements_to_installr�to_dict�open�json�dump�sortedr$r�r�get_requirement�satisfied_by�!pip._internal.self_outdated_check�KeyErrorr"rH�valuesr)r(r�format�get_installation_order�ignore_dependenciesrC�_determine_conflictsrBrrA�get_lib_location_guessesr�sort�operator�
attrgetter�iter_all_distributionsr��canonical_namer��getr�append�_warn_about_conflicts�determine_resolver_variant�OSError�create_os_error_message�errorr�_handle_target_dirr\r#)/rarfrg�#installing_into_current_environmentr<�target_temp_dir�target_temp_dir_pathrVrmrnrtrs�	directory�reqsrw�reqrv�resolver�requirement_set�report�f�would_install_items�pip_reqr�r�r��
reqs_to_build�_�build_failures�
to_install�	conflicts�should_warn_about_conflictsrB�	installed�
lib_locations�env�summary�installed_versions�distribution�package�display_namer��text�installed_descr��show_traceback�messages/                                               rc�runzInstallCommand.run
sG��� � �W�%7�%7�%C��H�I�I����=�W�%=�%=�>�
,��!�!�T�)�
,��"�"�d�*�
,��#�#�t�+�		,�
0��7�7�$�&�,���?�?�&�7�7���)�)�'��E����z�?�#4�5� 3��!�!��+�+��)�)��'�'�!�/�/�!
���48��.2�����'+�G�$�!#������1C�1C�!D�G�������w�1�1�2��G�G�M�M�'�"4�"4�5�#�S���
,��:�O�#2�#7�#7� �����/� �/�/�5�2���*�*�7�3��*�7�3�
��+�+���'�#*�#A�#A�	,�
���*�*�+<�+>�?�
�!��'�'�'��!�
�	�m	��(�(��w���H�D�)�'�4�8�$�W�%6�%6�7�K�
��-1��*���5�5�(��+���%�3�3��.�.�6��H��)�)�!���'�%�3�3�!(�!9�!9�'.�'E�'E� '� 7� 7�!1�"�-�-� '� 6� 6�*��H�
�!�!�&�)�&�.�.���1C�1C�-C�/��O��'�'�+�O�,S�,S�T���+�+�s�2��F�N�N�$4�5��g�6�6��g�N�RS��	�	�&�.�.�"2�A�a�e�T�O����&,�-�,�D�D�-�'�#�'� �*���� P�<O� P�P����

=�)�9�9�%�@��!(� 4� 4�� <�
� �
=�4�=�Q�)�5�5�<�<�>��>�A�3�A�6��>�
��!&��'�� �-�!��A�~��'�9�9?���	�	�!A�.�!A�A�:���"�8�8��I�J�48�I��/�/�/�P�G�4P�4P�
(�+� �5�5�j�A�	�$+�#?�#?� ��!�!�W�%8�%8�',�$�*����&�&�)��*�*�%9�%�3�3�!�/�/�	�I�5��*�*�)��&�&��*�*� �.�.��M�"�-�0�C�
�N�N�x�2�2�6�:�N�;��G�!#�� #� :� :� <��BN�BV�BV�"�<�#>�#>�?�!=�$��&�|�|��,�0�0�1B�<�1P�RV�W���*�^�1�W�I�6�D�'�D����t�$�%��$��*�*��%)�%D�%D�W�%M�+��
!�X�X�g�.�N���/�"�� ���"�"�?��#�#��"�"�O�W�_�_�
��#�#�v�-��!���QO�N��"�
&� %�
�
&����l�
	�!�^�^�q�0�N�-����%�%��G�

�L�L��>�L�:��L��
	�sj�&E\/�?(\�'A\/�\�=\/�\*�$H\/�\�\/�\'�#\/�&\'�'\/�/	^�8A^�:^�^r4r�r;c���t|�g}td|j��}|j}|j}|j
}tjj|�r|j|�tjj|�r||k7r|j|�tjj|�r|j|�|D�]h}	t
j|	�D�]L}
|	|k(r8tjj||
��t�fd�|ddD��r�Atjj||
�}tjj|�r�|stjd|���tjj|�rtjd|���tjj|�rt!j"|�nt
j$|�t!j&tjj|	|
�|���O��ky)N�)r�c3�@�K�|]}|j�����y�wr�)�
startswith)r��s�ddirs  �rcr�z4InstallCommand._handle_target_dir.<locals>.<genexpr>)s�����I�7H�!�1�<�<��-�7H�s����zKTarget directory %s already exists. Specify --upgrade to force replacement.z�Target directory %s already exists and is a link. pip will not automatically replace links, please remove if replacement is desired.)r rr��purelib�platlibr{r�r�r��listdirr��anyr��warning�islinkr��shutil�rmtree�remove�move)
rar4r�r;�lib_dir_list�scheme�purelib_dir�platlib_dir�data_dir�lib_dirr��target_item_dirr�s
            @rcr�z!InstallCommand._handle_target_dirs����	�:�����B�_�%9�%9�:���n�n���n�n���;�;��
�7�7�>�>�+�&�����,�
�7�7�>�>�+�&�;�+�+E�����,�
�7�7�>�>�(�#�����)�#�G��
�
�7�+���h�&��7�7�<�<��$�7�D��I�|�C�R�7H�I�I� �"$�'�'�,�,�z�4�"@���7�7�>�>�/�2�"����>�+��
!��w�w�~�~�o�6����'�,��!��w�w�}�}�_�5��
�
�o�6��	�	�/�2����B�G�G�L�L��$�7��I�9,�$rer�c�b�	t|�S#t$rtjd�YywxYw)NzwError while checking for conflicts. Please file an issue on pip's issue tracker: https://github.com/pypa/pip/issues/new)r�	Exceptionr��	exception)rar�s  rcr�z#InstallCommand._determine_conflictsDs:��	�*�:�6�6���	����N�
��	�s�

�.�.�conflict_detailsr�c���|\}\}}|s|syg}|dk(r|jd�n|dk(sJ�|jd�|D]3}||d}||D]!}	|�d|�d|	d�d	�}
|j|
��#�5|D]G}||d}||D]5\}}}
d
j|||
|||dk(rdnd�
�}
|j|
��7�Itjdj	|��y)N�legacyz�pip's legacy dependency resolver does not consider dependency conflicts when selecting packages. This behaviour is the source of the following dependency conflicts.�
resolvelibz�pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.rr�z
 requires r�z, which is not installed.zg{name} {version} requires {requirement}, but {you} have {dep_name} {dep_version} which is incompatible.�youzyou'll)r�r��requirement�dep_name�dep_versionr�
)r�r�r��criticalr�)rar
r��package_set�missing�conflicting�parts�project_namer��
dependencyr�rrr�s              rcr�z$InstallCommand._warn_about_conflictsPsE��/?�+��+�g�{��{�����x�'��L�L�@�
�$�|�3�3�3��L�L�@�
�$�L�!�,�/��2�G�%�l�3�
�#�n�A�g�Y�j��A���H.�.�����W�%�4�$�(�L�!�,�/��2�G�.9�,�.G�*��+�s�F��&�%�#� #�%� +�"2�l�"B���
������W�%�/H�(� 	����	�	�%�(�)re)r,N)�__name__�
__module__�__qualname__�__doc__�usagerdr
rr�str�intr�r%�boolr�rrrr�r��rercr+r+5s���
�
0�E�
�B�A�6�A��c��A�s�A��A�F4J��4J�0=�4J�HL�4J�	
�4J�l
��1�2�
�	�/�	"�
�0*� /�0*�CF�0*�	
�0*rer+r�r�r�r�r�r,c�T�td|||||��}|j|jgS)Nr�)r�r�r�r�r�)rr�r�)r�r�r�r�r�rs      rcr�r��s5���
�
�
�
���
�F�
�N�N�F�N�N�+�+rec	�N�td�tt||���D��S)Nc3�2K�|]}t|����y�wr�r)r��ds  rcr�z)site_packages_writable.<locals>.<genexpr>�s�����L�A�	�!��L�s��r�r�)�all�setr�r's  rc�site_packages_writabler*�s)�����-�4�(�K�L���rer7r:r4r9rjc��|�|stjd�y|r8|rtd��t�rt	d��tjd�y|�J�|s|rtjd�yt
jstjd�yt||�	�rtjd
�ytjd�y)aZDetermine whether to do a user install based on the input options.

    If use_user_site is False, no additional checks are done.
    If use_user_site is True, it is checked for compatibility with other
    options.
    If use_user_site is None, the default behaviour depends on the environment,
    which is provided by the other arguments.
    z$Non-user install by explicit requestFzVCan not combine '--user' and '--prefix' as they imply different installation locationszZCan not perform a '--user' install. User site-packages are not visible in this virtualenv.z User install by explicit requestTz3Non-user install due to --prefix or --target optionz4Non-user install because user site-packages disabledr'z0Non-user install because site-packages writeablezMDefaulting to user installation because normal site-packages is not writeable)	r��debugrr'r�site�ENABLE_USER_SITEr*�info)r7r:r4r9rjs     rcr�r��s���"	�!�M����;�<�����3��
� �!�#�6��
�	���7�8��� � � ��j����J�K��� � ����K�L���9�}�E����G�H��
�K�K�	��rer�r��using_user_sitec��g}|jd�|s,|jd�|jt|��n|jd�|dxxdz
cc<|jtjk(rUd}d}t	�s%|s#|j|d|j
�g�n|j|�|jd	�trR|jtjk(r5|jr)t|j�d
kDr|jd�dj|�j�dzS)
zrFormat an error message for an OSError

    It may occur anytime during the execution of the install command.
    z,Could not install packages due to an OSErrorz: �.r�rz"Consider using the `--user` optionzCheck the permissionsz or z.
iz�HINT: This error might have occurred since this system does not have Windows Long Path support enabled. You can find information on how to enable this at https://pip.pypa.io/warnings/enable-long-paths
r�)
r�r�errno�EACCESr&�extend�lowerr�ENOENT�filename�lenr��strip)r�r�r0r�user_option_part�permissions_parts      rcr�r��s��
�E�
�L�L�?�@��
���T��
���S��Z� �
���S��
�"�I���I�
�{�{�e�l�l�"�?��2��'�)�/��L�L�$��$�*�*�,��
�
�L�L�)�*�
���U��
	��K�K�5�<�<�'��N�N������#�%�
���
?�	
��7�7�5�>���!�D�(�(re)FNNFN)NNNF)Nr3r�r�r�r�r-�optparserr�typingrr�pip._vendor.packaging.utilsr�pip._vendor.richr�pip._internal.cacher	�pip._internal.clir
�pip._internal.cli.cmdoptionsr�pip._internal.cli.req_commandrr
�pip._internal.cli.status_codesrr�pip._internal.exceptionsrr�pip._internal.locationsr�pip._internal.metadatar�(pip._internal.models.installation_reportr�,pip._internal.operations.build.build_trackerr�pip._internal.operations.checkrr�pip._internal.reqr�pip._internal.req.req_installrr�pip._internal.utils.compatr�pip._internal.utils.filesystemr�pip._internal.utils.loggingr�pip._internal.utils.miscrr r!r"r#r$�pip._internal.utils.temp_dirr%�pip._internal.utils.virtualenvr&r'�pip._internal.wheel_builderr(r)rr�r+r!rr�r*r�r�r�r"rerc�<module>rUs������	�
��*�!�9�'�*�(�;��:�D�.�2�G�J�S�0��/�<�1���7��P�	�8�	��K	*�'�K	*�^���� �,�
�,�
�3�-�,��3�-�,��	,�

�S�M�,�
�#�Y�
,�$��#���$��4��"&� $�#��:��D�>�:��#��:���
�:���}�	:�
�:�
�
:�z6)��6)�$(�6)�;?�6)��6)re

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists