+
    =i                         R t ^ RIt^ RIt^ RIHt ^ RIHtHtHtH	t	 ^RI
Ht ]	! R]R7      t ! R R]4      t ! R	 R
]4      t ! R R]4      t ! R R]4      tR R ltR R ltR R ltR R lt]]]3tR# )zThe purpose of this module is implement PEP 621 validations that are
difficult to express as a JSON Schema (or that are not supported by the current
JSON Schema library).
N)cleandoc)	GeneratorIterableMappingTypeVar)ValidationErrorT)boundc                   "    ] tR t^tRt]tRtRtR# )RedefiningStaticFieldAsDynamiczAccording to PEP 621:

    Build back-ends MUST raise an error if the metadata specifies a field
    statically as well as being listed in dynamic.
    zMhttps://packaging.python.org/en/latest/specifications/pyproject-toml/#dynamic N__name__
__module____qualname____firstlineno___DESC__doc___URL__static_attributes__r       Wlib/python3.14/site-packages/setuptools/config/_validate_pyproject/extra_validations.pyr   r      s    E
 GW 	r   r   c                   "    ] tR t^tRt]tRtRtR# ) IncludedDependencyGroupMustExistzDAn included dependency group must exist and must not be cyclic.
    z!https://peps.python.org/pep-0735/r   Nr   r   r   r   r   r      s    EG.Dr   r   c                   "    ] tR t^#tRt]tRtRtR# )ImportNameCollisionz\According to PEP 794:

    All import-names and import-namespaces items must be unique.
    !https://peps.python.org/pep-0794/r   Nr   r   r   r   r   r   #       E G.Dr   r   c                   "    ] tR t^,tRt]tRtRtR# )ImportNameMissingzLAccording to PEP 794:

    An import name must have all parents listed.
    r   r   Nr   r   r   r   r   r   ,   r   r   r   c                0    V ^8  d   QhR\         R\         /#    	pyprojectreturnr   )formats   "r   __annotate__r'   5   s       a r   c           
         V P                  R / 4      pVP                  R. 4      pV FU  pW19   g   K  \        RV R2W1V,          RRRV/RV 2R\        \        P                  4      R\        P                  /R	R
7      h	  V # )projectdynamicz(You cannot provide a value for `project.z6` and list it under `project.dynamic` at the same timez...z # ...zdata.project.descriptionseezPEP 621messagevaluename
definitionrule)getr   r   r   r   )r#   project_tabler*   fields   &   r   validate_project_dynamicr6   5   s    MM)R0M	2.G!0B5' JC C /8w
 %UG,!8,J,P,P#Q9>>   $ r   c                0    V ^8  d   QhR\         R\         /# r!   r%   )r&   s   "r   r'   r'   N   s      !  r   c                 `   V P                  R / 4      pVP                  4        F  w  r#V F|  p\        V\        4      '       g   K  VP                  R4      ;p'       g   K6  WQ9  g   K>  \	        RV R2VRV 2R\        \        P                  4      R\        P                  /RR7      h	  K  	  V # )	zdependency-groupszinclude-groupzThe included dependency group z doesn't existzdata.dependency_groups.r+   r,   zPEP 735r-   )r3   items
isinstancedictr   r   r   r   )r#   dependency_groupskeyr/   eachinclude_groups   &     r   validate_include_depenencyr@   N   s    !&92>'--/
D4&&&*hh&??]??!:6<]O>Z23%8%x0P0V0V'W?DD  #	 	  0$ r   c                b    V ^8  d   QhR\         \        ,          R\        \        RR3,          /# )r"   r9   r$   N)r   strr   )r&   s   "r   r'   r'   e   s)     . .8C= .YsD$-G .r   c              #   p   "   V  F+  pVP                  R 4      ^ ,          P                  4       x  K-  	  R# 5i);N)	partitionrstrip)r9   items   & r   _remove_privaterH   e   s,     nnS!!$++-- s   46c                0    V ^8  d   QhR\         R\         /# r!   r%   )r&   s   "r   r'   r'   j   s     & &1 & &r   c                    V P                  R / 4      p\        P                  ! \        VP                  R. 4      4      4      p\        P                  ! \        VP                  R. 4      4      4      pW#,           P	                  4        UUu. uF  w  rEV^8  g   K  VNK  	  pppV'       d:   \        RVRR\        \
        P                  4      R\
        P                  /RR7      h\        W#,           4      pV Fs  p\        P                  ! VP                  R	4      R
R R 4       FB  p	W9  g   K  \        RVRR\        \        P                  4      R\        P                  /RR7      h	  Ku  	  V # u uppi )r)   zimport-nameszimport-namespaceszBDuplicated names are not allowed in import-names/import-namespaceszdata.project.importnames(paces)r+   r,   zPEP 794r-   .Nc                     V  R V 2# )rK   r   )abs   &&r   <lambda>-validate_import_name_issues.<locals>.<lambda>   s    !AaSzr   zRAll parents of an import name must also be listed in import-namespace/import-names)r3   collectionsCounterrH   r9   r   r   r   r   	frozenset	itertools
accumulatesplitr   )
r#   r)   import_namesimport_namespaceskv
duplicatednamesr0   parents
   &         r   validate_import_name_issuesr_   j   s]   mmIr*G&&w{{>SU7V'WXL#++$7<= ".!A H H JT JaRSe!! JJT!X2x(;(A(AB*// 	
 		
 l67E**JJsOCR "9
F "'p:%x0A0G0G'H055  #	 		
   ? Us   
E0E0)r   rR   rU   inspectr   typingr   r   r   r   error_reportingr   r   r   r   r   r   r6   r@   rH   r_   EXTRA_VALIDATIONSr   r   r   <module>rd      s   
    8 8 ,Cw	_ 	/ /// // /2..
&T  r   