
    g                    \    d dl mZ d dlZd dlmZmZ ddZ e       dd	 	 	 	 	 	 	 	 	 d	dZy)
    )annotationsN)AnyCallablec                H    t        j                  |       }||j                  v S )zBReturns whether or not the given function has a specific parameter)inspect	signature
parameters)funcarg_namesigs      N/var/www/openai/venv/lib/python3.12/site-packages/openai/_utils/_reflection.pyfunction_has_argumentr      s!    


D
!Cs~~%%     )exclude_paramsdescriptionc                   t        j                  |      }t        j                  |       }g }|j                  j                         D ]  \  }}||v r|j                  j	                  |      }	|	s|j                  d| d       >|	j                  |j                  k7  sX|j                  d| dt        |j                         dt        |	j                                 |r,t        t        |       d| ddj                  |      z         y	)
zCEnsure that the signature of the second function matches the first.zthe `z` param is missingztypes for the `z!` param are do not match; source=z
 checking=z- errors encountered when comparing signaturesz:

z

N)r   r   r	   itemsgetappend
annotationreprAssertionErrorlenjoin)
source_func
check_funcr   r   	check_sig
source_sigerrorsnamesource_paramcustom_params
             r   assert_signatures_in_syncr$      s1    !!*-I"";/JF(3399;l>! ++//5MME$'9:;""l&=&==MM!$'HlNeNeIfHggqrv  xD  xO  xO  sP  rQ  R  < 6{mHUZ[^d^i^ijp^qq
 	
 r   )r
   Callable[..., Any]r   strreturnbool)
r   r%   r   r%   r   zset[str]r   r&   r'   None)	
__future__r   r   typingr   r   r   setr$    r   r   <module>r.      sP    "   &  #u 
# 
" 
 	 

  
 
 
r   