o
    ˜ÄŽi±  ã                   @   s¢   U d Z ddlmZmZ ddlmZmZmZmZm	Z	m
Z
 e	dd„ e
dd„ edd„ edd„ ed	d„ ed
d„ iZeee eegef f ed< dedee fdd„ZdS )zCLI error handling utilities.é    )ÚCallableÚOptional)ÚGatedRepoErrorÚHfHubHTTPErrorÚLocalTokenNotFoundErrorÚRemoteEntryNotFoundErrorÚRepositoryNotFoundErrorÚRevisionNotFoundErrorc                 C   ó   dS )Nz~Repository not found. Check the `repo_id` and `repo_type` parameters. If the repo is private, make sure you are authenticated.© ©Úer   r   úW/home/jeff/fluffinator/venv/lib/python3.10/site-packages/huggingface_hub/cli/_errors.pyÚ<lambda>   s   r   c                 C   r
   )Nz3Revision not found. Check the `revision` parameter.r   r   r   r   r   r       ó    c                 C   r
   )Nz1Access denied. This repository requires approval.r   r   r   r   r   r   !   r   c                 C   r
   )Nz)Not logged in. Run 'hf auth login' first.r   r   r   r   r   r   "   r   c                 C   r
   )NzFile not found in repository.r   r   r   r   r   r   #   r   c                 C   s   t | ƒS ©N)Ústrr   r   r   r   r   $   s    ÚCLI_ERROR_MAPPINGSr   Úreturnc                 C   s,   t  ¡ D ]\}}t| |ƒr|| ƒ  S qd S r   )r   ÚitemsÚ
isinstance)r   Úexc_typeÚ	formatterr   r   r   Úformat_known_exception(   s
   
ÿr   N)Ú__doc__Útypingr   r   Úhuggingface_hub.errorsr   r   r   r   r   r	   r   ÚdictÚtypeÚ	Exceptionr   Ú__annotations__r   r   r   r   r   Ú<module>   s    "ø