U
    ui                     @   s  U d dl Z d dlmZmZmZmZmZmZmZm	Z	 d dl
mZ e jdkrG dd dZG dd dZG d	d
 d
ZG dd dZG dd dZG dd dZG dd dZG dd dZG dd dZG dd dZG dd dZG dd dZG dd dZG dd  d ZG d!d" d"ZG d#d$ d$ZG d%d& d&Zd'd(lmZm Z  d)d*ee ee!eeeeed+ f ef ee"ee"ef f f d,d-d.Z#nd'd/l$mZ d'd0l$mZ d'd1l$mZ d'd2l$mZ d'd3l$mZ d'd4l$mZ d'd5l$mZ d'd6l$mZ d'd7l$mZ d'd8l$mZ d'd9l$mZ d'd:l$mZ d'd;l$mZ d'd<l$mZ d'd=l$mZ d'd>l$mZ d'd?l$mZ d'd(l$mZm Z  d'd@l$m#Z# e dAZ%ee e&dB< ee eee"ef  dCdDdEZ'ee ee	e"e(f dFf eee"ef  dGdHdIZ)dS )J    N)AnyDictListLiteralSequenceTupleTypeUnion)ModelNameMap)      c                   @   s   e Zd ZdS )AnyUrlN__name__
__module____qualname__ r   r   P/home/lhs5088/backend/venv/lib/python3.8/site-packages/fastapi/_compat/may_v1.pyr      s   r   c                   @   s   e Zd ZdS )
BaseConfigNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )	BaseModelNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )ColorNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )
CoreSchemaNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )ErrorWrapperNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )	FieldInfoNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )GetJsonSchemaHandlerNr   r   r   r   r   r      s   r   c                   @   s   e Zd ZdS )JsonSchemaValueNr   r   r   r   r   r       s   r   c                   @   s   e Zd ZdS )
ModelFieldNr   r   r   r   r   r   #   s   r   c                   @   s   e Zd ZdS )	NameEmailNr   r   r   r   r   r   &   s   r   c                   @   s   e Zd ZdS )RequiredParamNr   r   r   r   r   r   )   s   r   c                   @   s   e Zd ZdS )SecretBytesNr   r   r   r   r   r   ,   s   r   c                   @   s   e Zd ZdS )	SecretStrNr   r   r   r   r   r    /   s   r    c                   @   s   e Zd ZdS )	UndefinedNr   r   r   r   r   r!   2   s   r!   c                   @   s   e Zd ZdS )UndefinedTypeNr   r   r   r   r   r"   5   s   r"   c                   @   s   e Zd ZdS )UrlNr   r   r   r   r   r#   8   s   r#      )ValidationErrorcreate_modelT)separate_input_output_schemas)Z
validationZserialization)fieldsmodel_name_mapr'   returnc                 C   s   i i fS )Nr   )r(   r)   r'   r   r   r   get_definitions=   s    r+   )r   )r   )r   )r   )r   )r   )r   )r   )r   )r   )r   )r   )r   )r    )r!   )r"   )r#   )r+   RequestRequestErrorModel)errorsr*   c                 C   s^   g }| D ]P}t |tr4t|gtd }|| qt |trN|t| q|| q|S )N)r.   model)	
isinstancer   r%   r-   r.   extendlist_normalize_errorsappend)r.   Z
use_errorserrorZ
new_errorsr   r   r   r3   d   s    
 

r3   .)r.   
loc_prefixr*   c                    s    fddt | D }|S )Nc              	      s$   g | ]}|d  | d d iqS )locr   )get).0errr6   r   r   
<listcomp>v   s   z._regenerate_error_with_loc.<locals>.<listcomp>)r3   )r.   r6   Zupdated_loc_errorsr   r;   r   _regenerate_error_with_locs   s    
r=   )*systypingr   r   r   r   r   r   r   r	   Zfastapi.typesr
   version_infor   r   r   r   r   r   r   r   r   r   r   r   r   r    r!   r"   r#   Zv2r%   r&   boolstrr+   Zv1r-   __annotations__r3   intr=   r   r   r   r   <module>   sx    (  