관리-도구
편집 파일: found_candidates.cpython-311.pyc
� �Dg� � �t � d Z ddlZddlZddlmZ ddlmZmZmZm Z m Z mZmZ ddl mZ ddlmZ ddlmZ ej e� � Zeeeg e e f f Zer ee ZneZd e e d e e fd�Zded e e d e e fd �Zded e e d e e fd�Z G d� de� � ZdS )a� Utilities to lazily create and visit candidates found. Creating and visiting a candidate is a *very* costly operation. It involves fetching, extracting, potentially building modules from source, and verifying distribution metadata. It is therefore crucial for performance to keep everything here lazy all the way down, so we only touch candidates that we absolutely need, and not "download the world" when we only need one version of something. � N)�Sequence)� TYPE_CHECKING�Any�Callable�Iterator�Optional�Set�Tuple)�_BaseVersion)�MetadataInvalid� )� Candidate�infos�returnc # �4 K � t � � }| D ]�\ }}||v r� |� � }|��|V � |� |� � �2# t $ rF}t � d||j j |� � |� |� � Y d}~�}d}~ww xY wdS )z�Iterator for ``FoundCandidates``. This iterator is used when the package is not already installed. Candidates from index come later in their normal ordering. NzpIgnoring version %s of %s since it has invalid metadata: %s Please use pip<24.1 if you need to use this version.)�set�addr �logger�warning�ireq�name)r �versions_found�version�func� candidate�es ��/builddir/build/BUILD/imunify360-venv-2.4.0/opt/imunify360/venv/lib/python3.11/site-packages/pip/_internal/resolution/resolvelib/found_candidates.py�_iter_builtr * s� � � � � ),���N�� (� (� ����n�$�$�� (�����I� � ���O�O�O����w�'�'�'�'��! � (� (� (��N�N�G� ����� � � � ���w�'�'�'�'�'�'�'�'����� (����(� (s � A� B�<B�B� installedc # � K � | V � | j h}|D ]0\ }}||v r� |� � }|��|V � |� |� � �1dS )aK Iterator for ``FoundCandidates``. This iterator is used when the resolver prefers the already-installed candidate and NOT to upgrade. The installed candidate is therefore always yielded first, and candidates from index come later in their normal ordering, except skipped when the version is already installed. N)r r �r r r r r r s r �_iter_built_with_prependedr"