a
    oDf                     @   sD   d Z ddlZddlmZ eeejj dddZeddddZ	dS )	z This module defines a function for iterating over entry points
as well as for loading them.
It is copied almost entirely from the entrypoint handling in the excellent
Hypothesis package https://github.com/HypothesisWorks/hypothesis.
    N)Iterator)groupreturnc                 c   sF   zt jj| d}W n$ ty6   t j | g }Y n0 |E d H  d S )N)r   )	importlibmetadataZentry_points	TypeErrorget)r   Zeps r	   _/nfs/NAS7/SABIOD/METHODE/ermites/ermites_venv/lib/python3.9/site-packages/panel/entry_points.pyentry_points_for   s
    r   c                 C   s(   t | D ]}| }t|r|  qd S )N)r   loadcallable)r   entryhookr	   r	   r
   load_entry_points   s    r   )
__doc__importlib.metadatar   typingr   strr   
EntryPointr   r   r	   r	   r	   r
   <module>   s   