
    hs                     ~   U 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
 d dlm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 d dlmZ d dlZd dlmZmZmZm Z m!Z! d dl"m#Z# dd	l$m%Z% dd
l&m'Z' ddl(m)Z)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3 ddl4m5Z5 ddl6m7Z7 ddl8m9Z9m:Z: ddl;m<Z<m=Z= ddl>m?Z?m@Z@mAZAmBZBmCZC ddlDmEZE ddlFmGZG dZHerddlImJZJ ddlKmLZL ddlMmNZN  ejO        ddd           G d d                      ZPejQ        ejR        z   dz   ZSeeT         eUd<   deS dZVeeT         eUd<   d W                    d!X                    d" d# eY eZd$d%                    z   D                                 Z[eeT         eUd&<   d'Z\eeT         eUd(<   d)W                    e[e\*          Z]eeT         eUd+<   d,W                    eVe]-          Z^eeT         eUd.<    ej_        d/          Z`eeeT                  eUd0<    ej_        e^          ZaeeeT                  eUd1<    G d2 d3eeTef         e/          Zb G d4 d5eb          ZcdS )6    N)SimpleCookie)MappingProxyType)TYPE_CHECKINGAnyDictFinalIteratorMappingMutableMappingOptionalPatternTupleUnioncast)	parse_qsl)CIMultiDictCIMultiDictProxy	MultiDictMultiDictProxyMultiMapping)URL   )hdrs)AbstractStreamWriter)	_SENTINELDEBUGETAG_ANYLIST_QUOTED_ETAG_REChainMapProxyETagHeadersMixinparse_http_datereifysentinelset_exception)RawRequestMessage)HttpVersion)BodyPartReaderMultipartReader)EmptyStreamReaderStreamReader)DEFAULT_JSON_DECODERJSONDecoderLooseHeaders
RawHeadersStrOrURL)HTTPRequestEntityTooLarge)StreamResponse)BaseRequest	FileFieldRequest)Application)RequestHandler)UrlMappingMatchInfoT)auto_attribsfrozenslotsc                   X    e Zd ZU eed<   eed<   ej        ed<   eed<   ee         ed<   dS )r4   namefilenamefilecontent_typeheadersN)__name__
__module____qualname__str__annotations__ioBufferedReaderr        U/var/www/html/prod/cognitive/venv/lib/python3.11/site-packages/aiohttp/web_request.pyr4   r4   L   sP         
IIIMMM

c""""""rJ   r4   z!#$%&'*+.^_`|~-_TCHAR[z]+_TOKENz[{}] c              #   4   K   | ]}t          |          V  d S N)chr).0cs     rK   	<genexpr>rU   [   s(      KKSVVKKKKKKrJ   )	       !   #      _QDTEXTz
\\[\t !-~]_QUOTED_PAIRz"(?:{quoted_pair}|{qdtext})*")qdtextquoted_pair_QUOTED_STRINGz0({token})=({token}|{quoted_string})(:\d{{1,4}})?)tokenquoted_string_FORWARDED_PAIRz\\([\t !-~])_QUOTED_PAIR_REPLACE_RE_FORWARDED_PAIR_REc                   ,   e Zd ZU ej        ej        ej        ej        ej        hZ	e
j         eg d          z  ZdZeeeeeef                           ed<   dZee         ed<   dddddddeded	d
dedddej        dedeeeef                  dee         dee         dee         ddfdZeeeeeeeddeee f         dee!e f         dee"e f         deee f         deee f         deee f         deee f         dd fdZ#e$d`d            Z%e$dad            Z&e$deej'                 fd            Z(e$defd            Z)e$defd            Z*e+defd             Z,e+de-fd!            Z.e+dej        fd"            Z/d#edefd$Z0d#ed%eddfd&Z1d#eddfd'Z2defd(Z3de4e         fd)Z5e+de6fd*            Z7e+de8e9eef         d+f         fd,            Z:e+defd-            Z;e+defd.            Z<e+de=fd/            Z>e+defd0            Z?e+dee         fd1            Z@e+de-fd2            ZAe+defd3            ZBe+defd4            ZCe+defd5            ZDe+dbd7            ZEe+defd8            ZFe+deGe         fd9            ZHe+deIfd:            ZJe+deeKjK                 fd;            ZLe+deeKjK                 fd<            ZMeNd=ede4eO         fd>            ZPeQd?ee         dee8eOd+f                  fd@            ZRe+dee8eOd+f                  fdA            ZSe+dee8eOd+f                  fdB            ZTe+deeKjK                 fdC            ZUe+de6fdD            ZVe+de9eef         fdE            ZWe+deXfdF            ZYe+defdG            ZZe$de6fdH            Z[e$de6fdI            Z\e+de6fdJ            Z]dcdKZ^defdLZ_defdMZ`eadNdOebdefdPZcdedfdQZedddSZfdedTedUedefdVZgdefdWZhdXeide6fdYZjde6fdZZkd[elddfd\Zmd]enddfd^Zodcd_ZpdS )fr3   )_message	_protocol_payload_writer_payload_headers_method_version_rel_url_post_read_bytes_state_cache_task_client_max_size_loop_transport_sslcontext_transport_peernameNrn   ro   i   )client_max_sizestateschemehostremotemessagepayloadprotocolr7   payload_writertaskasyncio.Task[None]looprw   rx   ry   rz   r{   returnc                Z   || _         || _        || _        || _        |j        | _        |j        | _        |j        | _	        i | _
        |j        }|j        rp|	|                    |	          }|
|                    |
          }|| j
        d<   |j        | j
        d<   |j        | j
        d<   |                                | _        n|| _        |	
|	| j
        d<   |

|
| j
        d<   |i n|| _        || _        || _        || _        |j        | _        |j        | _        ||| j
        d<   d S d S )Nurlrz   ry   r{   )rf   rg   rh   ri   rA   rj   methodrk   versionrl   rq   r   absolutewith_scheme	with_hostrz   ry   relativerm   rp   rr   rs   rt   ssl_contextru   peernamerv   )selfr|   r}   r~   r   r   r   rw   rx   ry   rz   r{   r   s                rK   __init__zBaseRequest.__init__   sC     !-/6~&(k< 	+!oof--mmD)) "%DK"%(DK$'JDK!LLNNDMMDM!(.H%&*F#!Mbbu
 /
%-%9"#+#4 $*DK!!! rJ   r   rel_urlrA   ry   rz   r{   rw   r   r   rA   c                   | j         rt          d          i }|t          ur||d<   |t          ur&t          |          }	|	|d<   t	          |	          |d<   |t          urSt          t          |                    |d<   t          d |d                                         D                       |d<    | j	        j
        di |}
i }|t          ur||d<   |t          ur||d	<   |t          ur||d
<   |t          u r| j        } | j        |
| j        | j        | j        | j        | j        f|| j                                        d|S )a  Clone itself with replacement some attributes.

        Creates and returns a new instance of Request object. If no parameters
        are given, an exact copy is returned. If a parameter is not passed, it
        will reuse the one from the current request object.
        z.Cannot clone request after reading its contentr   r   pathrA   c              3   p   K   | ]1\  }}|                     d           |                     d           fV  2dS )utf-8N)encode)rS   kvs      rK   rU   z$BaseRequest.clone.<locals>.<genexpr>   sW       ' 'Aq '""AHHW$5$56' ' ' ' ' 'rJ   raw_headersry   rz   r{   )rw   rx   rI   )ro   RuntimeErrorr$   r   rE   r   r   tupleitemsrf   _replacers   	__class__ri   rg   rh   rr   rt   rp   copy)r   r   r   rA   ry   rz   r{   rw   dctnew_urlr|   kwargss               rK   clonezBaseRequest.clone   s   "  	QOPPP !!"CM(""w<<G CJg,,CK(""-k'.B.BCCC	N!& ' '	N0022' ' ' " "C
 )$-(//3//!!%F8x!F6N!!%F8h&&"3Ot~MN JJ

 ,+""$$

 

 

 

 
	
rJ   c                     | j         S rQ   )rr   r   s    rK   r   zBaseRequest.task
  s
    zrJ   c                     | j         S rQ   )rg   r   s    rK   r~   zBaseRequest.protocol  s
    ~rJ   c                 ,    | j         d S | j         j        S rQ   )rg   	transportr   s    rK   r   zBaseRequest.transport  s    >!4~''rJ   c                     | j         S rQ   )rh   r   s    rK   writerzBaseRequest.writer  s    ##rJ   c                     | j         S rQ   )rs   r   s    rK   rw   zBaseRequest.client_max_size  s    $$rJ   c                 H    t          j        dt          d           | j        S )NzRequest.message is deprecated   
stacklevel)warningswarnDeprecationWarningrf   r   s    rK   r|   zBaseRequest.message   s$    57IVWXXXX}rJ   c                     | j         S rQ   )rm   r   s    rK   r   zBaseRequest.rel_url%  s
    }rJ   c                 H    t          j        dt          d           | j        S )Nz#request.loop property is deprecated   r   )r   r   r   rt   r   s    rK   r   zBaseRequest.loop)  s.    13ERS	
 	
 	
 	
 zrJ   keyc                     | j         |         S rQ   rp   r   r   s     rK   __getitem__zBaseRequest.__getitem__2  s    {3rJ   valuec                     || j         |<   d S rQ   r   )r   r   r   s      rK   __setitem__zBaseRequest.__setitem__5  s     CrJ   c                     | j         |= d S rQ   r   r   s     rK   __delitem__zBaseRequest.__delitem__8  s    KrJ   c                 *    t          | j                  S rQ   )lenrp   r   s    rK   __len__zBaseRequest.__len__;  s    4;rJ   c                 *    t          | j                  S rQ   )iterrp   r   s    rK   __iter__zBaseRequest.__iter__>  s    DK   rJ   c                     | j         dk    S )z5A bool indicating if the request is handled with SSL.https)ry   r   s    rK   securezBaseRequest.secureC  s     {g%%rJ   .c                    g }| j         j                            t          j        d          D ]}t          |          }d}d}i }|                    t          j        |                     d|cxk    r|k     rOn Pt          
                    ||          }||r|                    d|          }n|                                \  }}	}
|	d         dk    r#t                              d|	dd	                   }	|
r|	|
z  }	|	||                                <   |t          |                    d                    z  }d
}nw||         dk    r1d}i }|                    t          j        |                     |dz  }n:||         dk    rd}|dz  }n&||         dv r|dz  }n|                    d|          }d|cxk    r|k     I t#          |          S )a  A tuple containing all parsed Forwarded header(s).

        Makes an effort to parse Forwarded headers as specified by RFC 7239:

        - It adds one (immutable) dictionary per Forwarded 'field-value', ie
          per proxy. The element corresponds to the data in the Forwarded
          field-value added by the first proxy encountered by the client. Each
          subsequent item corresponds to those added by later proxies.
        - It checks that every value has valid syntax in general as specified
          in section 4: either a 'token' or a 'quoted-string'.
        - It un-escapes found escape sequences.
        - It does NOT validate 'by' and 'for' contents as specified in section
          6.
        - It does NOT validate 'host' contents (Host ABNF).
        - It does NOT validate 'proto' contents for valid URI scheme names.

        Returns a tuple containing one or more immutable dicts
        rI   r   FN,"z\1r   T;z 	)rf   rA   getallr   	FORWARDEDr   appendtypesr   rd   matchfindgroupsrc   sublowergroupr   )r   elemsfield_valuelengthposneed_separatorelemr   r=   r   ports              rK   	forwardedzBaseRequest.forwardedH  s   ( =077KK %	5 %	5K%%FC"N#%DLL/55666s####V#####*00cBB$% .)..sC88,1LLNN)eT 8s??$;$?$?uQrT{$S$SE *!TME-2TZZ\\*s5;;q>>222)- %,,%*NDLL!7!=!=>>>1HCC %,,%*N1HCC %.. 1HCC &**344C? s####V####@ U||rJ   c                     | j         rdS dS )a  A string representing the scheme of the request.

        Hostname is resolved in this order:

        - overridden value by .clone(scheme=new_scheme) call.
        - type of connection to peer: HTTPS if socket is SSL, HTTP otherwise.

        'http' or 'https'.
        r   http)ru   r   s    rK   ry   zBaseRequest.scheme  s     % 	76rJ   c                     | j         S )zyRead only property for getting HTTP method.

        The value is upper-cased str like 'GET', 'POST', 'PUT' etc.
        )rk   r   s    rK   r   zBaseRequest.method  s     |rJ   c                     | j         S )zxRead only property for getting HTTP version of request.

        Returns aiohttp.protocol.HttpVersion instance.
        )rl   r   s    rK   r   zBaseRequest.version  s     }rJ   c                     | j         j                            t          j                  }||S t          j                    S )a@  Hostname of the request.

        Hostname is resolved in this order:

        - overridden value by .clone(host=new_host) call.
        - HOST HTTP header
        - socket.getfqdn() value

        For example, 'example.com' or 'localhost:8080'.

        For historical reasons, the port number may be included.
        )rf   rA   getr   HOSTsocketgetfqdn)r   rz   s     rK   rz   zBaseRequest.host  s7     }$((33K~rJ   c                     | j         dS t          | j         t          t          f          rt	          | j         d                   S t	          | j                   S )zRemote IP of client initiated HTTP request.

        The IP is resolved in this order:

        - overridden value by .clone(remote=new_remote) call.
        - peername of opened socket
        Nr   )rv   
isinstancelistr   rE   r   s    rK   r{   zBaseRequest.remote  sR     #+4d.u>> 	4t/23334+,,,rJ   c                 r    t          j        | j        | j                                      | j                  S )zThe full URL of the request.)ry   	authority)r   buildry   rz   joinrm   r   s    rK   r   zBaseRequest.url  s-    
 ytyAAAFFt}UUUrJ   c                     | j         j        S )z_The URL including *PATH INFO* without the host or scheme.

        E.g., ``/app/blog``
        )rm   r   r   s    rK   r   zBaseRequest.path  s     }!!rJ   c                 *    t          | j                  S )zXThe URL including PATH_INFO and the query string.

        E.g, /app/blog?id=10
        )rE   rm   r   s    rK   path_qszBaseRequest.path_qs  s     4=!!!rJ   c                     | j         j        S )zThe URL including raw *PATH INFO* without the host or scheme.

        Warning, the path is unquoted and may contains non valid URL characters

        E.g., ``/my%2Fpath%7Cwith%21some%25strange%24characters``
        )rf   r   r   s    rK   raw_pathzBaseRequest.raw_path  s     }!!rJ   MultiMapping[str]c                     | j         j        S )z7A multidict with all the variables in the query string.)rm   queryr   s    rK   r   zBaseRequest.query  s     }""rJ   c                     | j         j        S )z:The query string in the URL.

        E.g., id=10
        )rm   query_stringr   s    rK   r   zBaseRequest.query_string  s     }))rJ   c                     | j         S )z4A case-insensitive multidict proxy with all headers.)rj   r   s    rK   rA   zBaseRequest.headers       }rJ   c                     | j         j        S )z$A sequence of pairs for all headers.)rf   r   r   s    rK   r   zBaseRequest.raw_headers  s     }((rJ   c                 d    t          | j                            t          j                            S )zyThe value of If-Modified-Since HTTP header, or None.

        This header is represented as a `datetime` object.
        )r"   rA   r   r   IF_MODIFIED_SINCEr   s    rK   if_modified_sincezBaseRequest.if_modified_since  s%     t|//0FGGHHHrJ   c                 d    t          | j                            t          j                            S )z{The value of If-Unmodified-Since HTTP header, or None.

        This header is represented as a `datetime` object.
        )r"   rA   r   r   IF_UNMODIFIED_SINCEr   s    rK   if_unmodified_sincezBaseRequest.if_unmodified_since  s%     t|//0HIIJJJrJ   etag_headerc              #     K   | t           k    rt          dt                     V  dS t          j        |           D ]B}|                    ddd          \  }}}|r dS t          t          |          |          V  CdS )z'Extract `ETag` objects from raw header.F)is_weakr   r   r      N)r   r    r   finditerr   bool)r  r   r  r   garbages        rK   _etag_valueszBaseRequest._etag_values  s       (""       
 -5kBB 
 
*/++aA*>*>'  EE MM      
 
rJ   header_valuec                 N    |sd S t          |                     |                    S rQ   )r   r
  )clsr  s     rK   _if_match_or_none_implz"BaseRequest._if_match_or_none_impl$  s-      	4S%%l33444rJ   c                 p    |                      | j                            t          j                            S )zxThe value of If-Match HTTP header, or None.

        This header is represented as a `tuple` of `ETag` objects.
        )r  rA   r   r   IF_MATCHr   s    rK   if_matchzBaseRequest.if_match-  s*     **4<+;+;DM+J+JKKKrJ   c                 p    |                      | j                            t          j                            S )z}The value of If-None-Match HTTP header, or None.

        This header is represented as a `tuple` of `ETag` objects.
        )r  rA   r   r   IF_NONE_MATCHr   s    rK   if_none_matchzBaseRequest.if_none_match5  s+     **4<+;+;D<N+O+OPPPrJ   c                 d    t          | j                            t          j                            S )zpThe value of If-Range HTTP header, or None.

        This header is represented as a `datetime` object.
        )r"   rA   r   r   IF_RANGEr   s    rK   if_rangezBaseRequest.if_range=  s$     t|//>>???rJ   c                     | j         j         S )zIs keepalive enabled by client?)rf   should_closer   s    rK   
keep_alivezBaseRequest.keep_aliveE  s     =---rJ   c                     | j                             t          j        d          }t	          |          }t          d |                                D                       S )zMReturn request cookies.

        A read-only dictionary-like object.
        rO   c                 $    i | ]\  }}||j         S rI   )r   )rS   r   vals      rK   
<dictcomp>z'BaseRequest.cookies.<locals>.<dictcomp>R  s      O O OHCci O O OrJ   )rA   r   r   COOKIEr   r   r   )r   rawparseds      rK   cookieszBaseRequest.cookiesJ  sO     lt{B//c"" O O O O OPPPrJ   c                    | j                             t          j                  }d\  }}|	 d}t	          j        ||          d         \  }}n# t          $ r t          d          w xY w|rt          |          nd}|rt          |          nd}||| }d}|||dz  }||k    rt          d          ||cxu rn nt          d          t          ||d          S )	zMThe content of Range HTTP header.

        Return a slice instance.

        )NNNz^bytes=(\d*)-(\d*)$r   zrange not in acceptable formatr   zstart cannot be after endz"No start or end of range specified)
rj   r   r   RANGErefindall
IndexError
ValueErrorintslice)r   rngstartendpatterns        rK   
http_rangezBaseRequest.http_rangeT  s&    m
++
s?C0Z55a8
ss C C C !ABBBC "+#c(((tC"'1CJJJTE} S_qC<<$%@AAA######## !EFFFUC###s    A A(c                     | j         S )zReturn raw payload stream.)ri   r   s    rK   contentzBaseRequest.contentx  r   rJ   c                 n    t          j        dt          d           | j                                         S )@Return True if request's HTTP BODY can be read, False otherwise.z$Deprecated, use .can_read_body #2005r   r   )r   r   r   ri   at_eofr   s    rK   has_bodyzBaseRequest.has_body}  s?     	24FST	
 	
 	
 	
 =''))))rJ   c                 6    | j                                          S )r3  )ri   r4  r   s    rK   can_read_bodyzBaseRequest.can_read_body  s     =''))))rJ   c                 8    t          | j                  t          uS )z6Return True if request has HTTP BODY, False otherwise.)typeri   r*   r   s    rK   body_existszBaseRequest.body_exists  s     DM""*;;;rJ   c                    K   | j                                         s:| j                                          d{V  | j                                         8dS dS )zKRelease request.

        Eat unread part of HTTP BODY if present.
        N)ri   r4  readanyr   s    rK   releasezBaseRequest.release  sp      
 -&&(( 	*-''))))))))) -&&(( 	* 	* 	* 	* 	*rJ   c                 F  K   | j         t                      }	 | j                                         d{V }|                    |           | j        r0t          |          }|| j        k    rt          | j        |          |snot          |          | _         | j         S )z_Read request body if present.

        Returns bytes object with full request content.
        NTmax_sizeactual_size)	ro   	bytearrayri   r<  extendrs   r   r1   bytes)r   bodychunk	body_sizes       rK   readzBaseRequest.read  s      
 #;;D
"m3355555555E"""(  #D		I D$9997%)%:	     
  %T{{DrJ   c                 v   K   |                                   d{V }| j        pd}|                    |          S )z1Return BODY as text using encoding from .charset.Nr   )rH  charsetdecode)r   
bytes_bodyencodings      rK   textzBaseRequest.text  sE      99;;&&&&&&
<*7  ***rJ   )loadsrO  c                P   K   |                                   d{V } ||          S )zReturn BODY as JSON.N)rN  )r   rO  rE  s      rK   jsonzBaseRequest.json  s3      YY[[      uT{{rJ   c                 :   K   t          | j        | j                  S )z3Return async iterator to process BODY as multipart.)r)   rj   ri   r   s    rK   	multipartzBaseRequest.multipart  s      t}dm<<<rJ   ,MultiDictProxy[Union[str, bytes, FileField]]c                 &  K   | j         | j         S | j        | j        vr't          t	                                | _         | j         S | j        }|dvr't          t	                                | _         | j         S t	                      }|dk    r|                                  d{V }| j        }|                                 d{V }|d}|j	        
                    t          j                  }t          |t                    rU|j        J |j        r}| j                            dt&          j                   d{V }|                    d           d{V }	|	r|                    |	          }	| j                            d|j        |	           d{V  |t1          |	          z  }d|cxk     r|k     r:n n7| j                            d|j                   d{V  t5          ||          |                    d           d{V }	|	| j                            d|j        d           d{V  |d}t9          |j        |j        t;          t<          j        |          ||j	                  }
|                     |j        |
           n|!                    d	
           d{V }||"                    d          rE|#                    d          }|                     |j        |                    |                     n|                     |j        |           |t1          |          z  }d|cxk     r|k     rn n!t5          ||          ntI          d          |                                 d{V }|no| !                                 d{V }|rS| j%        pd}|&                    tO          |(                                                    |          d	|                     t          |          | _         | j         S )zReturn POST parameters.N)rO   z!application/x-www-form-urlencodedmultipart/form-datarV  r   i   )sizer?  zapplication/octet-streamT)rK  ztext/r   )defaultz8To decode nested multipart you need to use custom reader)keep_blank_valuesrM  ))rn   rk   POST_METHODSr   r   r@   rS  rs   nextrA   r   r   CONTENT_TYPEr   r(   r=   r>   rt   run_in_executortempfileTemporaryFile
read_chunkrK  writer   closer1   seekr4   r   rG   rH   addrH  
startswithget_charsetr(  rJ  rC  r   rstrip)r   r@   outrS  r@  fieldrW  field_cttmprF  ffr   rJ  datas                 rK   postzBaseRequest.post  s     :!:<t000'	44DJ:(  
 
 

 (	44DJ:7@{{000"nn........I,H#..********E# =,,T->??e^44 4 :111 ~ )$(J$>$> ("8% %       ',&6&6E&6&B&B B B B B B B# 	G$)LL$7$7E"&*"<"<T39e"T"TTTTTTTT CJJ.D 82222d22222&*j&@&@sy&Q&Q Q Q Q Q Q Q Q&?-54'" '" '" !" +0*:*:*:*F*F$F$F$F$F$F$FE $ 	G #j88sxKKKKKKKKK#+'AH&!J!N !2C88$!M  
B//// ',jjj&=&= = = = = = =#+x/B/B7/K/K+&+&7&7&7&H&HGGGEJW0E0EFFFFGGEJ666E

*x....$.....";)1t# # #  /
 %R   (nn........u #x $$$$$$D ,1'

,,W55*.!(     $C((
zrJ   r=   rX  c                 Z    | j         }||S |j        }||S |                    ||          S )z"Extra info from protocol transport)rg   r   get_extra_info)r   r=   rX  r~   r   s        rK   rp  zBaseRequest.get_extra_info  s=    >N&	N''g666rJ   c                     | j                             dd                              d          }d                    | j        j        | j        |          S )Nasciibackslashreplacez<{} {} {} >)r   r   rK  formatr   rB   rk   )r   ascii_encodable_paths     rK   __repr__zBaseRequest.__repr__)  sW    #y//9KLLSS 
  
 ##N#T\3G
 
 	
rJ   otherc                 B    t          |           t          |          k    S rQ   )id)r   rw  s     rK   __eq__zBaseRequest.__eq__1  s    $xx2e99$$rJ   c                     dS )NTrI   r   s    rK   __bool__zBaseRequest.__bool__4  s    trJ   responsec                 
   K   d S rQ   rI   )r   r}  s     rK   _prepare_hookzBaseRequest._prepare_hook7  s      rJ   excc                 0    t          | j        |           d S rQ   )r%   ri   )r   r  s     rK   _cancelzBaseRequest._cancel:  s    dmS)))))rJ   c                     | j         | j        dk    rd S | j                                         D ]3\  }}t          |t                    r|j                                         4d S )NrV  )rn   r@   r   r   r4   r?   rb  )r   	file_namefile_field_objects      rK   _finishzBaseRequest._finish=  su    :!26K!K!KF -1J,<,<,>,> 	/ 	/(I(+Y77 /!&,,...	/ 	/rJ   )r   r   )r   r7   )r   r   )r   N)r   rT  rQ   )qrB   rC   rD   r   
METH_PATCH	METH_POSTMETH_PUT
METH_TRACEMETH_DELETErZ  r!   ATTRS	frozensetrn   r   r   r   rE   rD  r4   rF   ro   r&   r+   r   asyncioAbstractEventLoopr)  r   r   r   r$   r   r0   r.   r   propertyr   r~   	Transportr   r   rw   r#   r|   r   r   r   r   r   r   r   r	   r   r  r   r   r
   r   ry   r   r'   r   rz   r{   r   r   r   r   r   r   r   rA   r/   r   datetimer   r  staticmethodr    r
  classmethodr  r  r  r  r  r"  r*  r/  r1  r5  r7  r:  r=  rH  rN  r,   r-   rQ  r)   rS  rn  rp  rv  objectrz  r|  r2   r  BaseExceptionr  r  rI   rJ   rK   r3   r3   v   s
         	L 	
 	
 	
" " E* EIE8N5eY)>#?@AHHH#'K%'''  '*. $" $5+ 5+ 5+"5+ 5+ #	5+
 -5+ #5+ '5+ 5+ S#X'5+ 5+ sm5+ 5+ 
5+ 5+ 5+ 5+t )1.62:(0&.(0199
 9
 9
 c9n%9
 x*+	9

 |Y./9
 c9n%9
 CN#9
 c9n%9
 sI~.9
 
9
 9
 9
 9
v    X    X (8G$56 ( ( ( X(
 $, $ $ $ X$ % % % % X% *    U     U g/    U s  s        !s !3 !4 ! ! ! !s t             !(3- ! ! ! !
 & & & & U& :5c!2C!78 : : : U:x     U     U     U  c       U $ - - - - U- VS V V V UV "c " " " U" " " " " U" "# " " " U" # # # U# *c * * * U* )#.    U )Z ) ) ) U) I8H,=#> I I I UI KXh.?%@ K K K UK # (4.    \( 5#C=5	%c	"	#5 5 5 [5 L(5s#34 L L L UL QxdCi(89 Q Q Q UQ @(8#45 @ @ @ U@ .D . . . U. Qc* Q Q Q UQ !$E !$ !$ !$ U!$F     U *$ * * * X* *t * * * X* <T < < < U<* * * * E        *+C + + + + 2F   ; #    
= = = = =` ` ` `D
7 
73 
7 
7 
7 
7 
7 
7
# 
 
 
 
%F %t % % % %$    N t    *= *T * * * *
/ 
/ 
/ 
/ 
/ 
/rJ   r3   c                   ~    e Zd ZU ej         edg          z  ZdZed         ed<   e	rde
deddf fdZeeeeeeedd	ee
ef         d
eeef         deeef         dee
ef         dee
ef         dee
ef         deeef         dd f fdZedd            Zedd            Zedefd            ZdeddfdZ xZS )r5   _match_infoNr8   r=   r  r   c                     || j         vr:t          j        d                    | j        j        |          t          d           t                                          ||           d S )Nz-Setting custom {}.{} attribute is discouragedr   r   )	r  r   r   rt  r   rB   r   super__setattr__)r   r=   r  r   s      rK   r  zRequest.__setattr__R  sj    4:%%%%+VDN,CT%J%J& 	    GGc*****rJ   r   r   r   rA   ry   rz   r{   rw   c          	          t                                          |||||||          }t          t          |          }	| j        |	_        |	S )Nr   )r  r   r   r5   r  )r   r   r   rA   ry   rz   r{   rw   retnew_retr   s             rK   r   zRequest.clone\  sW     ggmm+  
 
 w$$".rJ   c                     | j         }|J |S )zResult of route resolving.)r  r   
match_infos     rK   r  zRequest.match_infot  s     %
%%%rJ   r6   c                 &    | j         }|J |j        S )zApplication instance.)r  current_appr  s     rK   appzRequest.app{  s!     %
%%%%%rJ   c                     | j         }|J |j        }| j        }|                    |          }t	          t          |d |dz                                }t          |          S )Nr   )r  appsr  indexr   reversedr   )r   r  lstr  idxsublists         rK   config_dictzRequest.config_dict  sb    %
%%%ohiinnxIcAgI//00W%%%rJ   r}  c                 ~   K   | j         }|d S |j        D ]'}|j        x}r|                    | |           d {V  (d S rQ   )r  _appson_response_preparesend)r   r}  r  r  r  s        rK   r  zRequest._prepare_hook  so      %
F# 	? 	?C&)&==" ?)..tX>>>>>>>>>	? 	?rJ   )r   r8   )r   r6   )rB   rC   rD   r3   r  r  r  r   rF   r   rE   r   r  r$   r   r   r0   r.   r)  r   r#   r  r  r  r   r  r2   r  __classcell__)r   s   @rK   r5   r5   J  s        		=/ : ::E37K/0777 
+	+C 	+c 	+d 	+ 	+ 	+ 	+ 	+ 	+ )1.62:(0&.(019   c9n% x*+	
 |Y./ c9n% CN# c9n% sI~. 
     0    U & & & X& &] & & & X&?N ?t ? ? ? ? ? ? ? ?rJ   r5   )dr  r  rG   r%  r   stringr^  r   r   http.cookiesr   r   typingr   r   r   r   r	   r
   r   r   r   r   r   r   urllib.parser   attr	multidictr   r   r   r   r   yarlr   rO   r   abcr   helpersr   r   r   r   r   r    r!   r"   r#   r$   r%   http_parserr&   http_writerr'   rS  r(   r)   streamsr*   r+   typedefsr,   r-   r.   r/   r0   web_exceptionsr1   web_responser2   __all__web_appr6   web_protocolr7   web_urldispatcherr8   sr4   digitsascii_lettersrL   rE   rF   rN   rt  r   r   ranger[   r\   r_   rb   compilerc   rd   r3   r5   rI   rJ   rK   <module>r     sj     				 				      % % % % % % " " " " " "                            # " " " " "                           % % % % % %                          + * * * * * $ $ $ $ $ $ 6 6 6 6 6 6 6 6 4 4 4 4 4 4 4 4              6 5 5 5 5 5 ( ( ( ( ( (
1  7$$$$$$,,,,,,666666 T$d333# # # # # # # 43# ]V%99<NNc
 N N N %&___c
 $ $ $nnHHKK/%%dD8I8I2J2JJKKKKK s    )eCj ( ( (=DD E  c
   
 8>>N ?   s    0:rz//J/J ws|, J J J +5"*_*E*E E'#,' E E EQ/ Q/ Q/ Q/ Q/.c*L Q/ Q/ Q/hH? H? H? H? H?k H? H? H? H? H?rJ   