o
    $6d                     @  s   d dl mZ d dlZd dlmZmZ d dlmZm	Z	 ddl
mZ ddlmZ es*eZdZG d	d
 d
eZe	dedG dd dedZG dd dZdS )    )annotationsN)TYPE_CHECKINGAny)Literal
deprecated   )_config)PydanticDeprecatedSince20)
BaseConfigExtrac                   @  s   e Zd ZdddZdS )	_ConfigMetaclassitemstrreturnr   c              
   C  sL   t tjt ztj| W S  ty% } ztd| j d| |d }~ww )Nztype object 'z' has no attribute )	warningswarnr   DEPRECATION_MESSAGEDeprecationWarningZconfig_defaultsKeyErrorAttributeError__name__selfr   exc r   qC:\Users\jesus\OneDrive\Desktop\erpjis_fastapi\backend\jisbackend\Lib\site-packages\pydantic/deprecated/config.py__getattr__   s   z_ConfigMetaclass.__getattr__Nr   r   r   r   )r   
__module____qualname__r   r   r   r   r   r      s    r   z@BaseConfig is deprecated. Use the `pydantic.ConfigDict` instead.)categoryc                      s0   e Zd ZdZd fddZd fd
dZ  ZS )r
   zThis class is only retained for backwards compatibility.

    !!! Warning "Deprecated"
        BaseConfig is deprecated. Use the [`pydantic.ConfigDict`][pydantic.ConfigDict] instead.
    r   r   r   r   c                   sp   t tjt zt |W S  ty7 } zztt	| |W W  Y d }~S  ty2   tt
||w d }~ww )N)r   r   r   r   r   super__getattribute__r   getattrtyper   r   	__class__r   r   r   %   s   zBaseConfig.__getattr__kwargsNonec                   s    t tjt t jdi |S )Nr   )r   r   r   r   r   r!   __init_subclass__)clsr'   r%   r   r   r)   0   s   zBaseConfig.__init_subclass__r   )r'   r   r   r(   )r   r   r   __doc__r   r)   __classcell__r   r   r%   r   r
      s    r
   )	metaclassc                      sD   e Zd ZU dZded< dZded< dZded< d fddZ  ZS )r   allowzLiteral['allow']ignorezLiteral['ignore']forbidzLiteral['forbid']_Extra__namer   r   r   c                   s   t jdtdd t |S )NzX`pydantic.config.Extra` is deprecated, use literal values instead (e.g. `extra='allow'`)r   )
stacklevel)r   r   r   r!   r"   )r   r1   r%   r   r   r"   :   s   zExtra.__getattribute__)r1   r   r   r   )	r   r   r   r.   __annotations__r/   r0   r"   r,   r   r   r%   r   r   5   s
   
 r   )
__future__r   Z_annotationsr   typingr   r   Ztyping_extensionsr   r   	_internalr   r	   r   __all__r$   r   r
   r   r   r   r   r   <module>   s    

