
     O=d?                     ~   d dl Z d dlZd dlZd dlZd dlZd dlZd dlZd dlZd dlZd dl	m
Z
mZmZmZmZmZmZmZmZmZmZmZmZmZ d dlmZmZ d dlmZmZ ej        rd dlm Z   ej!         e" ej#                                        Z$ ej!         e" e
j#                                        Z% ej!         e" ej#                                        Z& ej!         e" ej#                                        Z' ej!        d  ej#                    D                       Z( ej!        e          Z)dZ* ej+        d          Z,d	ej-        d
ej.        de/ddfdZ0 ej1        ddi           ej2        d           ej3        de4ddd           ej3        de5ddd           ej3        de4dd           ej3        de5dd           ej3        ddd d!"           ej3        d#d$dd% ej6        d&          '           ej3        d(d)dd*+           ej3        d,d-dd.+           ej3        d/e7d0dd12           ej3        d3de5d45           ej3        d6e(d7d8d           ej3        d9e%d7d:d           ej3        d;e&d7d<d           ej3        d=e5d>d?d           ej3        d@e7dAdBd           ej3        dCe7dAdDd           ej3        dEe/ddFd           ej3        dGe'd7dHd           ej3        dIe)d7dJd           ej3        dK ej6        d&          ddLd           ej3        dM ej6        d&          ddNd           ej3        dOe$ddPd           ej3        dQdddR"           ej3        dSdddT"           ej3        dUdddV"           ej3        dWdddX"           ej3        dYdddZ"           ej3        d[e4dd\           ej3        d]e4d^d_           ej3        d`e5dda           ej3        dbe5dcdd           ej3        dee5ddf           ej3        dge5dhdid           ej3        dje4ddkd           ej3        dle4ddmd           ej3        dne4ddod           ej3        dpe5 e5e          dqd           ej3        dre5 e5ej8                  dsd           ej3        dte4ddud           ej3        dve4dwdxd           ej3        dydzdd{+           ej3        d|de0d dd}~           ej3        dd^dd           ej3        dde5dd           ej3        ddd dd          de4de4de5de4de5dededede5de7de7de/dedede/d$ej9        e4         d)ej9        e4         d-ej9        e4         de7de5de4de4de4de/de/de/de/de4de4de5de5de5de5de4de4de4de5de5de4de4dzej9        e4         de/de4dej:        e5         de/ddf\d                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    Z;ddddd7d7d7d>dAdAdd7d7d dddd0ddeddddddd^ddcddhdddeej8        ddwdddd dd,dej<        dej=        e4f         de4de5dej:        e4         dej:        e5         dedej<        ej>        e j?                 ef         dej<        ej>        e j?                 ef         de5dej:        e7         dej:        e7         de/dedede/d$ej:        ej<        ej9        e4         e4f                  d)ej:        ej<        ej9        e4         e4f                  d-ej:        ej<        ej9        e4         e4f                  de7dej:        e5         dej:        ej<        e4ej@        f                  dej:        ej<        ejA        e4ejB        f         e4f                  dej:        ej<        e4e5f                  de/de/de/de/dej:        ej<        ej9        e4         e4f                  de4dej:        e5         de5dej:        e5         de5dej:        e4         dej:        ej<        e4ej@        f                  dej:        e4         de5de5dej:        e4         de4dzej:        ej9        ejC        e4e4f                           dej:        e/         dej:        e4         de/dej:        e5         ddf\dZDeEdk    r e;             dS dS )    N)HTTP_PROTOCOLS
INTERFACESLIFESPAN
LOG_LEVELSLOGGING_CONFIGLOOP_SETUPSSSL_PROTOCOL_VERSIONWS_PROTOCOLSConfigHTTPProtocolTypeInterfaceTypeLifespanTypeLoopSetupTypeWSProtocolType)ServerServerState)ChangeReloadMultiprocess)ASGIApplicationc                     g | ]
}|d k    |S )none ).0keys     6D:\Sites\api_v1\venv\Lib\site-packages\uvicorn/main.py
<listcomp>r   &   s    PPPS#--S---       uvicorn.errorctxparamvaluereturnc                     |r| j         rd S t          j        dt          j        dt          j                    dt          j                    dt          j                               | 	                                 d S )NzRunning uvicorn z with  z on )
resilient_parsingclickechouvicorn__version__platformpython_implementationpython_versionsystemexit)r    r!   r"   s      r   print_versionr0   .   s     C) 	JJ *,,,,#%%%%O	
   HHJJJJJr   auto_envvar_prefixUVICORN)context_settingsappz--hostz	127.0.0.1zBind socket to this host.T)typedefaulthelpshow_defaultz--porti@  zBind socket to this port.z--udszBind to a UNIX domain socket.)r5   r6   r7   z--fdz)Bind to socket from this file descriptor.z--reloadFzEnable auto-reload.)is_flagr6   r7   z--reload-dirreload_dirszRSet reload directories explicitly, instead of using the current working directory.)exists)multipler7   r5   z--reload-includereload_includeszSet glob patterns to include while watching for files. Includes '*.py' by default; these defaults can be overridden with `--reload-exclude`. This option has no effect unless watchfiles is installed.)r<   r7   z--reload-excludereload_excludeszSet glob patterns to exclude while watching for files. Includes '.*, .py[cod], .sw.*, ~*' by default; these defaults can be overridden with `--reload-include`. This option has no effect unless watchfiles is installed.z--reload-delayg      ?zTDelay between previous and next check if application needs to be. Defaults to 0.25s.)r5   r6   r8   r7   z	--workersz~Number of worker processes. Defaults to the $WEB_CONCURRENCY environment variable if available, or 1. Not valid with --reload.)r6   r5   r7   z--loopautozEvent loop implementation.z--httpzHTTP protocol implementation.z--wsz"WebSocket protocol implementation.z--ws-max-sizei   z#WebSocket max size message in bytesz--ws-ping-intervalg      4@zWebSocket ping intervalz--ws-ping-timeoutzWebSocket ping timeoutz--ws-per-message-deflatez)WebSocket per-message-deflate compressionz
--lifespanzLifespan implementation.z--interfacez:Select ASGI3, ASGI2, or WSGI as the application interface.z
--env-filezEnvironment configuration file.z--log-configzBLogging configuration file. Supported formats: .ini, .json, .yaml.z--log-levelzLog level. [default: info]z--access-log/--no-access-logzEnable/Disable access log.z--use-colors/--no-use-colorsz!Enable/Disable colorized logging.z"--proxy-headers/--no-proxy-headerszdEnable/Disable X-Forwarded-Proto, X-Forwarded-For, X-Forwarded-Port to populate remote address info.z"--server-header/--no-server-headerz%Enable/Disable default Server header.z--date-header/--no-date-headerz#Enable/Disable default Date header.z--forwarded-allow-ipszComma separated list of IPs to trust with proxy headers. Defaults to the $FORWARDED_ALLOW_IPS environment variable if available, or '127.0.0.1'.z--root-path zLSet the ASGI 'root_path' for applications submounted below a given URL path.z--limit-concurrencyz^Maximum number of concurrent connections or tasks to allow, before issuing HTTP 503 responses.z	--backlogi   z0Maximum number of connections to hold in backlogz--limit-max-requestszEMaximum number of requests to service before terminating the process.z--timeout-keep-alive   zLClose Keep-Alive connections if no new data is received within this timeout.z--ssl-keyfilezSSL key filez--ssl-certfilezSSL certificate filez--ssl-keyfile-passwordzSSL keyfile passwordz--ssl-versionz,SSL version to use (see stdlib ssl module's)z--ssl-cert-reqsz@Whether client certificate is required (see stdlib ssl module's)z--ssl-ca-certszCA certificates filez--ssl-ciphersTLSv1z(Ciphers to use (see stdlib ssl module's)z--headerheaderszASpecify custom default HTTP response headers as a Name:Value pairz	--versionz%Display the uvicorn version and exit.)r9   callbackexpose_valueis_eagerr7   z	--app-dirzuLook for APP in the specified directory, by adding this to the PYTHONPATH. Defaults to the current working directory.)r6   r8   r7   z--h11-max-incomplete-event-sizeh11_max_incomplete_event_sizezFFor h11, the maximum number of bytes to buffer of an incomplete event.z	--factoryzFTreat APP as an application factory, i.e. a () -> <ASGI app> callable.)r9   r6   r7   r8   hostportudsfdloophttpwsws_max_sizews_ping_intervalws_ping_timeoutws_per_message_deflatelifespan	interfacereloadreload_delayworkersenv_file
log_config	log_level
access_logproxy_headersserver_headerdate_headerforwarded_allow_ips	root_pathlimit_concurrencybackloglimit_max_requeststimeout_keep_alivessl_keyfilessl_certfilessl_keyfile_passwordssl_versionssl_cert_reqsssl_ca_certsssl_ciphers
use_colorsapp_dirfactoryc-                 V   t          | fi d|d|d|d|d|d|d|d|d	|	d
|
d|d|d|d|t          n|d|d|d|d|d|pd d|pd d|pd d|d|d|d|d|d|d|d|d|d|d | d!|!d"|"d#|#d$|$d%|%d&|&d'|'d(d) |(D             d*|)d+|,d,|*d-|+ d S ).NrH   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rX   rY   rZ   r[   rT   rU   r:   r=   r>   rV   rW   r\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rg   rh   ri   rj   rk   rC   c                 :    g | ]}|                     d d          S ):   )split)r   headers     r   r   zmain.<locals>.<listcomp>  s&    <<<&c1%%<<<r   rl   rn   rm   rG   )runr   )-r4   rH   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   r:   r=   r>   rV   rW   rX   rY   rZ   r[   r\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rg   rh   ri   rj   rk   rC   rl   rm   rG   rn   s-                                                r   mainrv   =   s   l
 . . .T. T. C	.
 2. T. T. 2.  K. *). (.  65. . . &0%7>>Z.  )!." :#.$ )%.& v'.(  '4).* (/4+., (/4-.. "\/.0 1.2 $m3.4 $m5.6  K7.8 0/9.: );.< ,+=.> ?.@ .-A.B .-C.D  KE.F "\G.H 21I.J  KK.L $mM.N "\O.P  KQ.R =<G<<<<S.T :U.V W.X Y.Z 'D&C[. . . .r   ),rH   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   r:   r=   r>   rV   rW   rX   rY   rZ   r[   r\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rg   rh   ri   rj   rk   rC   rl   rm   rn   rG   r   c       ,            |* t           j                            d|*           t          | fi d|d|d|d|d|d|d|d	|d
|	d|
d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d|d |d!| d"|!d#|"d$|#d%|$d&|%d'|&d(|'d)|(d*|)d+|+d,|,}-t	          |--          }.|-j        s|-j        d.k    rRt          | t                    s=t          j
        d/          }/|/                    d0           t          j        d.           |-j        r?|-                                }0t          |-|.j        |0g1                                           n^|-j        d.k    r?|-                                }0t#          |-|.j        |0g1                                           n|.                                 |-j        r=t&          j                            |-j                  rt'          j        |-j                   |.j        s-|-j        s(|-j        d.k    rt          j        t.                     d S d S d S d S )2Nr   rH   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   r:   r=   r>   rV   rW   rX   rY   rZ   r[   r\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rg   rh   ri   rj   rk   rC   rl   rn   rG   )configrr   r   zRYou must pass the application as an import string to enable 'reload' or 'workers'.)targetsockets)syspathinsertr   r   rU   rW   
isinstancestrlogging	getLoggerwarningr/   should_reloadbind_socketr   ru   r   rJ   osr;   removestartedSTARTUP_FAILURE)1r4   rH   rI   rJ   rK   rL   rM   rN   rO   rP   rQ   rR   rS   rT   rU   r:   r=   r>   rV   rW   rX   rY   rZ   r[   r\   r]   r^   r_   r`   ra   rb   rc   rd   re   rf   rg   rh   ri   rj   rk   rC   rl   rm   rn   rG   rx   serverloggersocks1                                                    r   ru   ru     s   d 7###- - -T- T- C	-
 2- T- T- 2-  K- *)- (-  65- - )- v-   K!-" (#-$ (%-& "\'-( )-* +-, :--. )/-0 :1-2 $m3-4 $m5-6  K7-8 0/9-: );-< ,+=-> ?-@ .-A-B .-C-D  KE-F "\G-H 21I-J  KK-L $mM-N "\O-P  KQ-R S-T :U-V W-X 'D&CY-F\ 6"""F !++ZS5I5I+"?33	
 	
 	
 	 !!##VFJ???CCEEEE	!		!!##VFJ???CCEEEE

z bgnnVZ00 
	&*> "&"6 "6>Q;N;N!!!!!" " " ";N;Nr   __main__)Fasyncior   r   r+   sslr{   typingr'   r)   uvicorn.configr   r   r   r   r   r   r	   r
   r   r   r   r   r   r   uvicorn.serverr   r   uvicorn.supervisorsr   r   TYPE_CHECKINGasgiref.typingr   ChoicelistkeysLEVEL_CHOICESHTTP_CHOICES
WS_CHOICESLIFESPAN_CHOICESLOOP_CHOICESINTERFACE_CHOICESr   r   r   Context	Parameterboolr0   commandargumentoptionr   intPathfloat	CERT_NONEListOptionalrv   UnionCallableTypeProtocolPathLikeDictAnyTupleru   __name__r   r   r   <module>r      s     				  



 



                                    / . . . . . . . : : : : : : : :	 /......TT/*/"3"34455u|DD!4!4!6!67788U\$$0|0223344
5<]X]__ 5 566 u|PP,<K,<,>,>PPPQQ EL,, 		?	+	+u} U_ T d     !5y ABBB		$   		$   gC4STTT
d)T   j$<QRRR
	4	 	 	    
@	   
	   	
   	
=	   		%   		(   
		-   		.   		"   		!   		4   		#   		E   	4	 	 	 	*   	4	 	 	 	M   		%   "	%	   "	,	   (
$	   (	0	   $	.	   	
S	   		W	   	
	   		;	   		P	   		W   #t.t   		   		   	C$%%	7   	C	K   		   		3   	L	   	0   
2	   %#		Q   	Q  ]	]
] ] 
	]
 	] ] ] 	] ] ] ] !] ] ] ]  S!!]" [%#]$ [%%]& ']( )]* +], -]. /]0 1]2 3]4 5]6 7]8 9]: ;]< =]> ?]@ A]B C]D E]F G]H I]J K]L M]N O]P Q]R [S]T U]V W]X $*?3#7Y]Z []\ 
]] ] ]                                         SR  UT    CBN	]F  $# JPFL/3.2#'#%HLLPLP$(@D 	9=PT.2/3(,DH15+)-DH(,$(:>ay" y" y"	'#=	>y" y" 	y"
 
	y" 	y" y" ,v{7#346FF
Gy" 	V[!12NBCy" y" oe,y" _U+y" !y" y" y"  !y"" fk#.>.C!DE#y"$ _V\&+c2BC2G%HI%y"& _V\&+c2BC2G%HI'y"( )y"* _S!+y", ofl3+;<=-y". V[fj1367/y"4 v|CH565y"6 7y"8 9y": ;y"< =y">  fk#6F6K)LM?y"@ Ay"B s+Cy"D Ey"F ,Gy"H Iy"J %Ky"L /&,sBK/?"@AMy"N !/#.Oy"P Qy"R Sy"T /#&Uy"V Wy"X _V[c3h)?@AYy"Z %[y"\ _S!]y"^ _y"` $*?3#7ay"b 
cy" y" y" y"x zDFFFFF r   