
    )h                         d dl mZ d dlmZ d dlmZmZmZ d dlm	Z	 ddl
mZmZ  ee      Z G d de	eeef         Z G d	 d
e	eeef         Zy)    )defaultdict)	getLogger)AnyDefaultDictOptional)BaseReporter   )	CandidateRequirementc                   (    e Zd ZddZdededdfdZy)PipReporterreturnNc                 B    t        t              | _        dddd| _        y )Nzpip is looking at multiple versions of {package_name} to determine which version is compatible with other requirements. This could take a while.zpip is still looking at multiple versions of {package_name} to determine which version is compatible with other requirements. This could take a while.zThis is taking longer than usual. You might need to provide the dependency resolver with stricter constraints to reduce runtime. See https://pip.pypa.io/warnings/backtracking for guidance. If you want to abort this run, press Ctrl + C.)r	         )r   intreject_count_by_package_messages_at_reject_countselfs    _/var/www/html/venv/lib/python3.12/site-packages/pip/_internal/resolution/resolvelib/reporter.py__init__zPipReporter.__init__   s)    >I#>N$9
9
K*
&    	criterion	candidatec                    | j                   |j                  xx   dz  cc<   | j                   |j                     }|| j                  vry | j                  |   }t        j	                  d|j                  |j                               d}|j                  D ]Y  }|j                  |j                  }}|dz  }|r ||j                   d|j                   dz  }n|dz  }||j                         z  }[ t        j                  |       y )	Nr	   zINFO: %s)package_namez0Will try a different candidate, due to conflict:z
     z depends on zThe user requested )r   namer   loggerinfoformatinformationrequirementparentversionformat_for_errordebug)	r   r   r   countmessagemsgreq_inforeqr%   s	            r   rejecting_candidatezPipReporter.rejecting_candidate#   s    $$Y^^494,,Y^^<666007JINN KL@!-- 	*H"..C8OC&++a'7|DD,,3''))C	* 	Sr   r   N)__name__
__module____qualname__r   r   r
   r.    r   r   r   r      s!    
,S Y 4 r   r   c                       e Zd ZdZddZdeddfdZdededdfdZdeddfd	Z	d
e
dee   ddfdZdededdfdZdeddfdZy)PipDebuggingReporterz9A reporter that does an info log for every event it sees.r   Nc                 .    t         j                  d       y )NzReporter.starting()r    r!   r   s    r   startingzPipDebuggingReporter.starting=   s    )*r   indexc                 0    t         j                  d|       y )NzReporter.starting_round(%r)r7   )r   r9   s     r   starting_roundz#PipDebuggingReporter.starting_round@   s    159r   statec                 ^    t         j                  d|       t         j                  d||       y )Nz Reporter.ending_round(%r, state)zReporter.ending_round(%r, %r))r    r!   r(   )r   r9   r<   s      r   ending_roundz!PipDebuggingReporter.ending_roundC   s"    6>4eUCr   c                 0    t         j                  d|       y )NzReporter.ending(%r)r7   )r   r<   s     r   endingzPipDebuggingReporter.endingG   s    )51r   r$   r%   c                 2    t         j                  d||       y )Nz#Reporter.adding_requirement(%r, %r)r7   )r   r$   r%   s      r   adding_requirementz'PipDebuggingReporter.adding_requirementJ   s     	9;Or   r   r   c                 2    t         j                  d||       y )Nz$Reporter.rejecting_candidate(%r, %r)r7   )r   r   r   s      r   r.   z(PipDebuggingReporter.rejecting_candidateO   s    :IyQr   c                 0    t         j                  d|       y )NzReporter.pinning(%r)r7   )r   r   s     r   pinningzPipDebuggingReporter.pinningR   s    *I6r   r/   )r0   r1   r2   __doc__r8   r   r;   r   r>   r@   r   r   r
   rB   r.   rE   r3   r   r   r5   r5   :   s    C+:C :D :D# Dc Dd D2C 2D 2P&P080CP	P
RS RY R4 R7 7t 7r   r5   N)collectionsr   loggingr   typingr   r   r    pip._vendor.resolvelib.reportersr   baser
   r   r0   r    strr   r5   r3   r   r   <module>rM      sR    #  - - 9 (	8	+,{Is:; +\7<Y(CD 7r   