� ��^i�n����UdZddlZddlZddlZddlmZddlmZmZm Z m Z m Z ddlm Z ddl mZmZmZmZmZddlmZddlmZdd lmZdd lmZdd lmZmZdd lmZdd l m!Z!ddl"m#Z#ddl$m%Z%ddl&m'Z'de dede(ddfd�Z)dee(efdede fd�Z* �d de dee ddfd�Z+�d de de,ddfd�Z-dede(de(de(fd �Z.dede(de(de(fd!�Z/Gd"�d#e��Z0eed$d%d&d&d'�(��Z1ed)efe2d*<eed+d,d-dd.�/��Z3ed)efe2d,<eed0d1d-dd2�/��Z4ed)efe2d1<eed3d4d5d-de�/��Z5ed)efe2d6<eed7d8d9d:dd;�/��Z6ed)efe2d9<eed�/��Z7ed)efe2d=<eed?d@dAd-dB�(��Z8ed)efe2dA<eedCdDdEd:ddF�/��Z9ed)efe2dE<eedGdHdIe:ej;����dJdKdL�<ej;����zdMz�N��Z=ed)efe2dH<ee0dOdPdQdRdSdSdT�U��Z>ed)efe2dR<eedVdWd-ddX�/��Z?ed)efe2dW<eedYdZd[d\d]�^��Z@ed)efe2dZ<eed_d`dadbdc�^��ZAed)efe2d`<eedddedfdgdhdidj�k��ZBed)efe2dg<defdl�ZCee0dmdndSdSdo�p��ZDed)efe2dn<ee0dqdrdSddSds�t��ZEed)efe2dr<eedudvdwdxdye!jFdz�{��ZGed)efe2dx<defd|�ZHeed}d~d-dd�/��ZIed)efe2d~<defd��ZJdefd��ZKdefd��ZLdefd��ZMdefd��ZNded�e(de(de ddf d��ZOee0d�d�d�d�d�dSd�e��d�eOd���� � ZPed)efe2d�<d�e dedefd��ZQded�e(de(de ddf d��ZRded�e(de(de ddf d��ZSdefd��ZTdefd��ZUeed�d�d�d�dd�����ZVed)efe2d�<de(deeeWd)fee(ffd��ZXded�e(de(de ddf d��ZYeed�d�d�d�eYd[de d������ � ZZed)efe2d�<eed�d�d�dd��{��Z[ed)efe2d�<eed�d�d�d�dd�����Z\ed)efe2d�<d�e ddfd��Z]de de#fd��Z^defd��Z_ee0d�d�ed�dSd�����Z`ed)efe2d�<dede(de(de ddf d��Zaeed�d�d�ead�����Zbed)efe2d�<eed�d�d�d-dd��/��Zced)efe2d�<eed�d�d-d��(��Zded)efe2d�<eed�d�d�d�dì/��Zeed)efe2d�<dede(de(de ddf dÅ„Zfeed�d�d-ddȬ/��Zgee2d�<eed�d�d�efde�ʦ�Zhee2d�<eed�d�d�ddάϦ�Zied)efe2d�<eed�d�dd�dÒ¬Ó¦�Zjed)efe2d�<eed�d�d�dd֬Ϧ�Zked)efe2d�<eed�d-ddج٦�Zled)efe2d�<eed�d-ddܬ٦�Zmed)efe2d�<eed�d�d-dd�/��Zned)efe2d�<ded�e(de(de ddf d�Zoeed�d�d�eod�d���Zped)efe2d�<eed�d�d-dd�/��Zqed)efe2d�<ee0d�dSdSd�d����Zred)efe2d�<de ddfd�Zsee0d�d�d�d�d�d�����Zted)efe2d�<eed�d�d-dd��/��Zued)efe2d�<eed�d�d�d�ggd��d�����Zved)efe2�d<ee�d�dd�d�g�d�dg�d����Zwed)efe2�d<�de1e3e4e5e6e8e9e>e?e@eAeBeCeKeDeEe`ebene7euevewg�d�Zxee(efe2�d <�d eGeHeIeJg�d�Zyee(efe2�d <dS(aC shared options and groups The principle here is to define options once, but *not* instantiate them globally. One reason being that options with action='append' can carry state between parses. pip parses general options twice internally, and shouldn't pass on state. To be consistent, all options will follow this design. �N)�partial)� SUPPRESS_HELP�Option� OptionGroup� OptionParser�Values)�dedent)�Any�Callable�Dict�Optional�Tuple��canonicalize_name)�ConfigOptionParser)� BAR_TYPES)� CommandError)�USER_CACHE_DIR�get_src_prefix)� FormatControl)�PyPI)� TargetPython)� STRONG_HASHES)� strtobool�parser�option�msg�returnc��|�d|��}tjd�|�������}|�|��dS)z� Raise an option parsing error using parser.error(). Args: parser: an OptionParser instance. option: an Option instance. msg: the error text. z error: � N)�textwrap�fill�join�split�error)rrrs ��/builddir/build/BUILDROOT/alt-python311-pip-21.3.1-4.el8.x86_64/opt/alt/python311/lib/python3.11/site-packages/pip/_internal/cli/cmdoptions.py�raise_option_errorr'"sR��� "� "�S� "� "�C� �-���������-�-� .� .�C� �L�L��������groupc��t||d��}|dD]}|�|����� |S)z� Return an OptionGroup object group -- assumed to be dict with 'name' and 'options' keys parser -- an optparse Parser �name�options)r� add_option)r)r� option_grouprs r&�make_option_groupr/0sN�� �v�u�V�}�5�5�L�� �"�*�*���������)�)�)�)� �r(r,� check_optionsc������|�dtdttf�fd� }gd�}tt ||����r3|j}|���tjdd���dSdS) z�Disable wheels if per-setup.py call options are set. :param options: The OptionParser options to update. :param check_options: The options to check, if not supplied defaults to options. N�nrc�&��t�|d��S�N)�getattr)r2r0s �r&�getnamez+check_install_build_global..getnameHs����}�a��.�.�.r()� build_options�global_options�install_optionszbDisabling all use of wheels due to the use of --build-option / --global-option / --install-option.�)� stacklevel) �strr r �any�map�format_control�disallow_binaries�warnings�warn)r,r0r6�names�controls ` r&�check_install_build_globalrE<s������� �/�3�/�8�C�=�/�/�/�/�/�/� C� B� B�E� �3�w�� � ��� ��(���!�!�#�#�#�� � 4�� � � � � � � � r(F� check_targetc��t|j|j|j|jg��}t t ��dh��}|j|ko|j }|r|rtd���|r|r|j std���dSdSdS)z�Function for determining if custom platform options are allowed. :param options: The OptionParser options. :param check_target: Whether or not to check if --target is being used. z:all:z�When restricting platform and interpreter constraints using --python-version, --platform, --abi, or --implementation, either --no-deps must be set, or --only-binary=:all: must be set and --no-binary must not be set (or must be set to :none:).zQCan not use any platform or abi specific options unless installing via '--target'N) r=�python_version� platforms�abis�implementationr�setr?�ignore_dependenciesr� target_dir)r,rF�dist_restriction_set� binary_only�sdist_dependencies_alloweds r&�check_dist_restrictionrRVs��� � � "� � � �L� � "�  ���� �����y�1�1�K���+�-�Q�g�6Q�2Q��� � :� �� � � � ��� � ��(:� ��,��� ��� � � � r(�opt�valuec�@�tj�|��Sr4)�os�path� expanduser�rrSrTs r&�_path_option_checkrZ~s�� �7� � �e� $� $�$r(c� �t|��Sr4rrYs r&�_package_name_option_checkr\�s�� �U� #� #�#r(c�h�eZdZejdzZej���Zeed<eed<dS)� PipOption)rW� package_namer_rWN) �__name__� __module__� __qualname__r�TYPES� TYPE_CHECKER�copyr\rZ�r(r&r^r^�sE������ �L�3� 3�E��&�+�+�-�-�L�#=�L�� �-�L����r(r^z-hz--help�helpz Show help.)�dest�actionrg.�help_z--debug� debug_mode� store_truezbLet unhandled exceptions propagate outside the main subroutine, instead of logging them to stderr.�rhri�defaultrgz --isolated� isolated_modezSRun pip in an isolated mode, ignoring environment variables and user configuration.z--require-virtualenvz--require-venv� require_venv�require_virtualenvz-vz --verbose�verbose�countzDGive more output. Option is additive, and can be used up to 3 times.z --no-color�no_colorzSuppress colored output.z-Vz --version�versionzShow version and exit.z-qz--quiet�quietz�Give less output. Option is additive, and can be used up to 3 times (corresponding to WARNING, ERROR, and CRITICAL logging levels).z--progress-bar� progress_bar�choice�onz*Specify type of progress to be displayed [�|z] (default: %default))rh�type�choicesrnrgz--logz --log-filez --local-log�logrWz Path to a verbose appending log.)rh�metavarr{rgz --no-input�no_inputzDisable prompting for input.z--proxy�proxyr<�z/src". The default for global installs is "/src".)rhr{r~rnrir�rg�srcr�c�,�t||j��S)zGet a format_control object.)r5rh)r�rs r&�_get_format_controlr��s�� �6�6�;� '� '�'r(c�p�t|j|��}tj||j|j��dSr4)r�r�r�handle_mutual_excludes� no_binary� only_binary�rr�rTr�existings r&�_handle_no_binaryr��sC��#�6�=�&�9�9�H��(� ���������r(c�p�t|j|��}tj||j|j��dSr4)r�r�rr�r�r�r�s r&�_handle_only_binaryr��sC��#�6�=�&�9�9�H��(� ���������r(c ��tt��t����}tdddtd|d���S)Nz --no-binaryr?r�r<avDo not use binary packages. Can be supplied multiple times, and each time adds to the existing value. Accepts either ":all:" to disable all binary packages, ":none:" to empty the set (notice the colons), or one or more package names with commas between them (no colons). Note that some packages are tricky to compile and may fail to install when this option is used on them.�rhrir�r{rnrg)rrLrr��r?s r&r�r��sH��"�3�5�5�#�%�%�0�0�N� �� ��"� ��D� � � � r(c ��tt��t����}tdddtd|d���S)Nz --only-binaryr?r�r<aKDo not use source packages. Can be supplied multiple times, and each time adds to the existing value. Accepts either ":all:" to disable all source packages, ":none:" to empty the set, or one or more package names with commas between them. Packages without binary distributions will fail to install when this option is used on them.r�)rrLrr�r�s r&r�r�sG��"�3�5�5�#�%�%�0�0�N� �� ��$� ��"� � � � r(z --platformrI�platformr�z�Only use wheels compatible with . Defaults to the platform of the running system. Use this option multiple times to specify multiple platforms supported by the target interpreter.r�c�>�|sdS|�d��}t|��dkrdSt|��dkr-|d}t|��dkr|d|dd�g} td�|D����}n#t$rYd SwxYw|dfS) z� Convert a version string like "3", "37", or "3.7.3" into a tuple of ints. :return: A 2-tuple (version_info, error_msg), where `error_msg` is non-None if and only if there was a parsing error. )NN�.�)rfz'at most three version parts are allowed�rNc3�4K�|]}t|��V��dSr4)r�)�.0�parts r&� z*_convert_python_version..8s(����9�9�4�S��Y�Y�9�9�9�9�9�9r()rfz$each version part must be an integer)r$�len�tuple� ValueError)rT�parts� version_infos r&�_convert_python_versionr�"s��� ���|� �K�K�� � �E� �5�z�z�A�~�~�>�>� �5�z�z�Q����a��� �u�:�:��>�>��1�X�u�Q�R�R�y�)�E�<��9�9�5�9�9�9�9�9� � �� �<�<�<�;�;�;�<���� �$� �s�0B � B�Bc��t|��\}}|�(d�||��}t|||���||j_dS)z3 Handle a provided --python-version value. Nz(invalid --python-version value: {!r}: {}�rr)r��formatr'r�rH)rr�rTrr�� error_msgrs r&�_handle_python_versionr�?s^�� 6�e�<�<��L�)���8�?�?� � � � �� �6�&�c�:�:�:�:�#/�F�M� � � r(z--python-versionrHa� The Python interpreter version to use for wheel and "Requires-Python" compatibility checks. Defaults to a version derived from the running interpreter. The version can be specified using up to three dot-separated integers (e.g. "3" for 3.0.0, "3.7" for 3.7.0, or "3.7.3"). A major-minor version can also be given as a string without dots (e.g. "37" for 3.7.0). )rhr~rir�r{rnrgz--implementationrKz�Only use wheels compatible with Python implementation , e.g. 'pp', 'jy', 'cp', or 'ip'. If not specified, then the current interpreter implementation is used. Use 'py' to force implementation-agnostic wheels.z--abirJ�abiaLOnly use wheels compatible with Python abi , e.g. 'pypy_41'. If not specified, then the current interpreter abi tag is used. Use this option multiple times to specify multiple abis supported by the target interpreter. Generally you will need to specify --implementation, --platform, and --python-version when using this option.�cmd_optsc��|�t����|�t����|�t����|�t ����dSr4)r-rIrHrKrJ)r�s r&�add_target_python_optionsr��sl�� ��� � � �$�$�$� ����(�(�)�)�)� ����(�(�)�)�)� ����������r(c�T�t|j|j|j|j���}|S)N)rI�py_version_inforJrK)rrIrHrJrK)r,� target_pythons r&�make_target_pythonr��s5�� ��#��.� �\��-� ���M� �r(c�*�tddddd���S)Nz--prefer-binary� prefer_binaryrlFz8Prefer older binary packages over newer source packages.rmr�rfr(r&r�r��s(�� �� ��� G�  � � �r(z --cache-dir� cache_dirzStore the cache data in .)rhrnr~r{rgc��|�G t|��n6#t$r)}t||t|�����Yd}~nd}~wwxYwd|j_dS)z� Process a value provided for the --no-cache-dir option. This is an optparse.Option callback for the --no-cache-dir option. Nr�F)rr�r'r<r�r�)rrSrTr�excs r&�_handle_no_cache_dirr��s��� �� D� �e� � � � ��� D� D� D� �v�f�#�c�(�(� C� C� C� C� C� C� C� C� C����� D����$�F�M���s�� A�A�Az--no-cache-dirzDisable the cache.)rhrir�rg�no_cachez --no-depsz--no-dependenciesrMz#Don't install package dependencies.�no_depsz--ignore-requires-python�ignore_requires_pythonz'Ignore the Requires-Python information.z--no-build-isolation�build_isolation� store_falseTz�Disable isolation when building a modern source distribution. Build dependencies specified by PEP 518 must be already installed if this option is used.�no_build_isolationc�J�|�d}t|||���d|j_dS)z� Process a value provided for the --no-use-pep517 option. This is an optparse.Option callback for the no_use_pep517 option. Na0A value was passed for --no-use-pep517, probably using either the PIP_NO_USE_PEP517 environment variable or the "no-use-pep517" config file option. Use an appropriate value of the PIP_USE_PEP517 environment variable or the "use-pep517" config file option instead. r�F)r'r�� use_pep517)rrSrTrrs r&�_handle_no_use_pep517r��s:�� �� �� �6�&�c�:�:�:�:� %�F�M���r(z --use-pep517r�z^Use PEP 517 for building source distributions (use --no-use-pep517 to force legacy behaviour).z--no-use-pep517)rhrir�rnrg� no_use_pep517z--install-optionr9a"Extra arguments to be supplied to the setup.py install command (use like --install-option="--install-scripts=/usr/local/bin"). Use multiple --install-option options to pass multiple options to setup.py install. If you are using an option with a directory path, be sure to use absolute path.)rhrir~rgz--build-optionr7z9Extra arguments to be supplied to 'setup.py bdist_wheel'.)rhr~rirgz--global-optionr8zcExtra global options to be supplied to the setup.py call before the install or bdist_wheel command.z --no-cleanz!Don't clean up build directories.)rirnrg�no_cleanz--prezYInclude pre-release and development versions. By default, pip only finds stable versions.�prez--disable-pip-version-check�disable_pip_version_checkz{Don't periodically check PyPI to determine whether a new version of pip is available for download. Implied with --no-index.c���|jjs i|j_ |�dd��\}}n8#t$r+|�d�|����YnwxYw|t vrA|�d�|d�t ������|jj�|g��� |��dS)zkGiven a value spelled "algo:digest", append the digest to a list pointed to in a dict by the algo name.�:r�zTArguments to {} must be a hash name followed by a value, like --hash=sha256:abcde...z&Allowed hash algorithms for {} are {}.z, N) r��hashesr$r�r%r�rr#� setdefaultr�)rr�rTr�algo�digests r&�_handle_merge_hashr�[s��� �=� �"�!�� �� ��{�{�3��*�*� ��f�f�� � � � �� � � ��v�g��� � � � � � ����  �=� � �� � � 4� ;� ;�����=�1�1� � � � � �  �M��#�#�D�"�-�-�4�4�V�<�<�<�<�Silence deprecation warnings for upcoming unsupported Pythons.z --use-feature�features_enabled�feature)z 2020-resolverz fast-depsz in-tree-buildzr s.����� � � � ���������������M�M�M�M�M�M�M�M�M�M�M�M�M�M�������7�7�7�7�7�7�7�7�7�7�7�7�7�7�9�9�9�9�9�9�7�7�7�7�7�7�5�5�5�5�5�5�1�1�1�1�1�1�B�B�B�B�B�B�B�B�=�=�=�=�=�=�+�+�+�+�+�+�;�;�;�;�;�;�4�4�4�4�4�4�.�.�.�.�.�.� �|� �V� �#� �$� � � � � �T�#�s�(�^� �5G� �K� � � � �8<� � � � �$,�V�$4� � � � � � �4%�%�F�%�$�%�4�%�%�%�%�P%�v�%�C�%��%��%�%�%�%�$�v�$�C�$��$��$�$�$�$�.�.�.�.�.��.�.�.� '�w� �� � � � �  � � ��x��V� �����%,�G� � � � � � -� %� %� %� �H�S�&�[� !� � � �(/�w� �� � � � � (� (� (� �x��V� �$� � � �-4�G� ��� � � � � -� -� -��H�S�&�[�)� � � �")�� ��� � � � O�"�"�"���#�v�+� ����#*�'� �� � � � #� #�#�#��(�3��;� ����")�� ��� � � !� "�"�"���#�v�+� ���� '�w� �� � � � � � � � ��x��V� �� � � �'.�g� �� � � �D����!�!� "� "� �4� �(�(�>�9�>�#�#� $� $� %� !� "� '� '� '� �h�s�F�{�#� � � �%�W� � ��� � � � +� � � ��X�c�6�k�� � � �#*�'� �� � � � '�#�#�#��(�3��;� ���� '�w� � � � � � G�  � � ��x��V� �����")�� �� � � � � "�"�"���#�v�+� ����")�� ��� � � � � =� "� "� "���#�v�+� � � � � �v� � � � �&�g� � � � � � � � � ��h�s�F�{�� � � �&-�W� �� � � � � 5� &� &� &� �X�c�6�k� "� � � �$+�7� ���� � � �O� � $� $� $� �8�C��K� � � � � �� � � � �#*�'� �� � � � L� #�#�#��(�3��;� ���� �F� � � � � �f� � � � � �V� � � � � �f� � � � � �&� � � � �/��/��/�S�/�,�/�SW�/�/�/�/� %�W� � ���� � � � �N� � � � � >�����X�c�6�k�����$(��(��(�3�(�(�(�(� � �� ��),��6B�� ������ �� ��),��6B�� ������6�����$�V�����$$+�7� �� � � � � J� $� $� $� �8�C��K� � � � �  �3� �5��s�C�x��(�3�-�1O�+P� � � � �:0� �0� �0�),�0�6B�0� �0�0�0�0�")0�� �� � � � #� � � �� � � �)�)�)����f��%����*)0�� �� � � � *� )� )� )����f��%� � � � &�g� � � � � � � �����h�s�F�{�����$ � � �� � � � ����<������v�����$+�7� �� � � � � )�$�$�$� �8�C��K� ����$� �$��$�%(�$�2>�$� �$�$�$�$�:#*�'� �� � � !� � #�#�#��(�3��;� ����")�� ��� � � � .�"�"�"���#�v�+� ����18�� �� !� � 2� 1�1�1����f��-����-4�G� �� � � � � -� -� -��H�S�&�[�)� � � �%� �%��%�%(�%�2>�%� �%�%�%�%�2�'� �� � � � 7� ��� �C�����W� �� � � "� � ���� �s����*1�� �� � � � 4� *� *� *���#�v�+�&� � � �(/�w� �� � � � D� (�(�(� �x��V� �$����)0�� �� � � � 6� )�)�)����f��%����#*�'� �� � � ,� #�#�#��(�3��;� ����%�W� � � � � &� ����X�c�6�k�����4;�7� �!� $� � � A� 4�4�4��8�C��K�0����=� �=� �=�),�=�6B�=� �=�=�=�=�0&�g� � � � � � � ?� � � ��h�s�F�{�� � � �)0�� �� � � � -� )� )� )����f��%� � � �$+�7� � � � � � -� $�$�$� �8�C��K� ����Q�F�Q�t�Q�Q�Q�Q� '.�g� �� � � � � 4�'�'�'� �h�s�F�{�#����4;�7� �!� $� � � I� 4�4�4��8�C��K�0����*1�� �� � � � � ;� ;� ;� G� *� *� *���#�v�+�&� � � �18�� �� &� � � � � 3� 4� P� 1� 1� 1����f��-� � � �" � ������ � �� ����� ����!��!���/�!�!� �t�C��H�~����< $����� ��� �T�#�s�(�^�����r(