
    q"h                        S SK r S SKrS SKrS SKrS SKJrJr  S SKJr  S SK	J
r
  SS\R                  R                   3S\R                  R                   S\R                  R                   3/r\
(       a7  SS1r\ R                   " \\5       V s/ s H  n SR#                  U 5      PM     sn rSS	\\\      S
\4S jjrS
\4S jrS
\4S jrgs  sn f )    N)ListOptional)main)WINDOWSpip. z.exeargsreturnc                 V    [         R                  R                  S5        [        U 5      $ )a  Central wrapper for all old entrypoints.

Historically pip has had several entrypoints defined. Because of issues
arising from PATH, sys.path, multiple Pythons, their interactions, and most
of them having a pip installed, users suffer every time an entrypoint gets
moved.

To alleviate this pain, and provide a mechanism for warning users and
directing them to an appropriate place for help, we now define all of
our old entrypoints as wrappers for the current one.
a  WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue.
To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
)sysstderrwriter   )r
   s    Q/var/www/html/env/lib/python3.13/site-packages/pip/_internal/utils/entrypoints.py_wrapperr      s'     JJ	" :    c                     [         (       a  SOSn [        R                  R                  [        R
                  U 5      n[        R                  R                  [        R                  R                  SS5      5      R                  [        R                  5      n[        R                  R                  U5      U;   nU(       a  [         H  n[        R                  " U5      n[        R                  R                  X5      nU(       d  MA  [        R                  R                  U5      (       d  Mg  [        R                  R                  UU5      (       d  M  Us  $    [!        5        S3$ )zHTry to figure out the best way to invoke pip in the current environment.ScriptsbinPATHr	   z -m pip)r   ospathjoinr   prefixnormcaseenvirongetsplitpathsep_EXECUTABLE_NAMESshutilwhichexistssamefile#get_best_invocation_for_this_python)binary_directorybinary_prefix
path_partsexe_are_in_PATHexe_namefound_executablebinary_executables          r    get_best_invocation_for_this_pipr-   .   s    $+GyGGLL-=>M !!"**.."<=CCBJJOJgg&&}5CO)H%||H5 "] E  GGNN#455GG$$$% 
   * 234G<<r   c                  <   [         R                  n [        R                  R	                  U 5      n[
        R                  " U5      nU(       aO  [        R                  R                  [        R                  " U5      [        R                  " U 5      5      (       a  U$ U $ )z<Try to figure out the best way to invoke the current Python.)	r   
executabler   r   basenamer!   r"   samestatlstat)exer*   r+   s      r   r%   r%   I   sj    
..Cww$H ||H- BGG,,RXX6F-GRUWW Jr   )N)	itertoolsr   r!   r   typingr   r   pip._internal.cli.mainr   pip._internal.utils.compatr   version_infomajorminorr    _allowed_extensionsproductr   strintr   r-   r%   )partss   0r   <module>r@      s     	  
 ! ' . 
	#


 
 	!"	#


 
 	!3#3#3#9#9":; 
 v, &&'8:MNNE 	N8DI& # .=# =6S qs   C