o
    hT                     @  sD   d dl mZ d dlZd dlmZmZ dd
dZe ddddZdS )    )annotationsN)AnyCallablefuncCallable[..., Any]arg_namestrreturnboolc                 C  s   t | }||jv S )zBReturns whether or not the given function has a specific parameter)inspect	signature
parameters)r   r   sig r   k/var/www/html/construction_image-detection-poc/venv/lib/python3.10/site-packages/groq/_utils/_reflection.pyfunction_has_argument   s   

r   )exclude_paramssource_func
check_funcr   set[str]Nonec          	   
   C  s   t |}t | }g }|j D ]6\}}||v rq|j|}|s,|d| d q|j|jkrG|d| dt|j dt|j  qq|rXtt	| dd
| dS )	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=z0 errors encountered when comparing signatures:

z

N)r   r   r   itemsgetappend
annotationreprAssertionErrorlenjoin)	r   r   r   	check_sig
source_sigerrorsnamesource_paramcustom_paramr   r   r   assert_signatures_in_sync   s&   

 r%   )r   r   r   r   r	   r
   )r   r   r   r   r   r   r	   r   )	
__future__r   r   typingr   r   r   setr%   r   r   r   r   <module>   s    

