
    ϶vg	                     V   d dl Z d dlZd dlZd dlmZ d dlmZ d dlmZ ddl	m
Z
 ddlmZ ddlmZ d	 Zd
 Zd Zde
j        fdZe j        d             Ze                    e          d             Ze                     ed          d            ede
j        fd            Zd ZdS )    N)	pass_none)yield_lines)consume   )metadata)ensure_unique)OptionErrorc                 t    	 | j          dS # t          t          f$ r}d|  d}t          |          |d}~ww xY w)zR
    Exercise one of the dynamic properties to trigger
    the pattern match.
    zProblems to parse zq.
Please ensure entry-point follows the spec: https://packaging.python.org/en/latest/specifications/entry-points/N)extrasAttributeErrorAssertionErrorr	   )epexmsgs      U/var/www/pixelcanvas.ch/venv/lib/python3.11/site-packages/setuptools/_entry_points.pyensure_validr      sg    
'
				N+ ' ' 'R R R R 	 #B&'s    727c                     t          |           }d| dd                    |          z   }t          j                            |          S )zf
    Given a value of an entry point or series of entry points,
    return each as an EntryPoint.
    []

)r   joinr   EntryPoints
_from_text)valuegrouplinestexts       r   
load_groupr      sF     Eu>>>DIIe,,,D**4000    c                     | j         | j        fS N)r   name)r   s    r   by_group_and_namer#   )   s    8RWr   epsc           	      r    t          t          t          t          | t                                         | S )zM
    Ensure entry points are unique by group and name and validate each.
    key)r   mapr   r   r#   r$   s    r   validater*   -   s/     CmC5FGGGHHIIIJr   c                     t           j                            d |                                 D                       }t	          t          j        |                    S )zA
    Given a Distribution.entry_points, produce EntryPoints.
    c              3   <   K   | ]\  }}t          ||          V  d S r!   )r   ).0r   r   s      r   	<genexpr>zload.<locals>.<genexpr>:   sA       + +%1UE
5%  + + + + + +r   )	itertoolschainfrom_iterableitemsr*   r   r   )r$   groupss     r   loadr4   5   sZ    
 _** + +58YY[[+ + +  F H(00111r   c                 ~    t          t          j        t          j                            |                               S )z
    >>> ep, = load('[console_scripts]\nfoo=bar')
    >>> ep.group
    'console_scripts'
    >>> ep.name
    'foo'
    >>> ep.value
    'bar'
    )r*   r   r   r   r)   s    r   _r6   @   s.     H()=)H)H)M)MNNOOOr   c                     | S r!    )xs    r   <lambda>r:   N   s    A r   c                     t          j        d          }t          j        t	          | |          |          }d                    d |D                       S )Nr   r&   r   c              3   H   K   | ]\  }}d | dt          |           dV  dS )r   r   r   N)render_items)r-   r   r2   s      r   r.   zrender.<locals>.<genexpr>V   sB      VV|ue:::<#6#6:::VVVVVVr   )operator
attrgetterr/   groupbysortedr   )r$   by_groupr3   s      r   renderrC   Q   sR    "7++Hvcx888(CCF99VVvVVVVVVr   c                 Z    d                     d t          |           D                       S )Nr   c              3   8   K   | ]}|j          d |j         V  dS )z = N)r"   r   )r-   r   s     r   r.   zrender_items.<locals>.<genexpr>Z   s4      EE2..BH..EEEEEEr   )r   rA   r)   s    r   r=   r=   Y   s)    99EEEEEEEEr   )	functoolsr/   r>   jaraco.functoolsr   jaraco.textr   more_itertoolsr   
_importlibr   
_itertoolsr   errorsr	   r   r   r#   r   r*   singledispatchr4   registerstrr6   typerC   r=   r8   r   r   <module>rQ      s            & & & & & & # # # # # # " " " " " "             % % % % % %      ' ' ' 1 1 1  (&     2 2 2 s
P 
P 
P dd4jj++ & & & W$ W W W WF F F F Fr   