+
    i                        ^ RI Ht ^ RIt^ RIt^ RIt^ RIt^RIHtHt ^RI	H
t
 ^RIHt ]P                  '       d   ^ RIHt ^ RIHt ]P$                  ! R4      tR	.tR
 R lt ! R R]
4      t ! R R	]4      tR# )    )annotationsN)RequestResponse)SyncByteStream)BaseTransport)
OptExcInfo)WSGIApplication_TWSGITransportc                    V ^8  d   QhRRRR/# )   bodyztyping.Iterable[_T]return )formats   "i/Users/igloo/.openclaw/workspace/scratch/fb_ad_env/lib/python3.14/site-packages/httpx/_transports/wsgi.py__annotate__r      s      %8 =P     c                r    \        V 4      p V  F%  pV'       g   K  \        P                  ! V.V 4      u # 	  . # N)iter	itertoolschain)r   chunks   & r   _skip_leading_empty_chunksr      s4    :D5??E7D11  Ir   c                  :    ] tR t^tR R ltR R ltR R ltRtR# )	WSGIByteStreamc                    V ^8  d   QhRRRR/# )r   resultztyping.Iterable[bytes]r   Noner   )r   s   "r   r   WSGIByteStream.__annotate__   s     : :5 :$ :r   c                	J    \        VR R4      V n        \        V4      V n        R# )closeN)getattr_closer   _result)selfr   s   &&r   __init__WSGIByteStream.__init__   s    fgt41&9r   c                   V ^8  d   QhRR/# )r   r   ztyping.Iterator[bytes]r   )r   s   "r   r   r!   #   s      0 r   c              #  	<   "   V P                    F  pVx  K	  	  R # 5ir   )r&   )r'   parts   & r   __iter__WSGIByteStream.__iter__#   s     LLDJ !s   c                   V ^8  d   QhRR/# )r   r   r    r   )r   s   "r   r   r!   '   s      t r   c                	F    V P                   e   V P                  4        R # R # r   )r%   )r'   s   &r   r#   WSGIByteStream.close'   s    ;;"KKM #r   )r%   r&   N)__name__
__module____qualname____firstlineno__r(   r-   r#   __static_attributes__r   r   r   r   r      s    : r   r   c                  6    ] tR t^,tRtRR R lltR R ltRtR# )	r   a  
A custom transport that handles sending requests directly to an WSGI app.
The simplest way to use this functionality is to use the `app` argument.

```
client = httpx.Client(app=app)
```

Alternatively, you can setup the transport instance explicitly.
This allows you to include any additional configuration arguments specific
to the WSGITransport class:

```
transport = httpx.WSGITransport(
    app=app,
    script_name="/submount",
    remote_addr="1.2.3.4"
)
client = httpx.Client(transport=transport)
```

Arguments:

* `app` - The WSGI application.
* `raise_app_exceptions` - Boolean indicating if exceptions in the application
   should be raised. Default to `True`. Can be set to `False` for use cases
   such as testing the content of a client 500 response.
* `script_name` - The root path on which the WSGI application should be mounted.
* `remote_addr` - A string indicating the client IP of incoming requests.
```
Nc               0    V ^8  d   QhRRRRRRRRRR	R
R/# )r   appr	   raise_app_exceptionsboolscript_namestrremote_addrwsgi_errorsztyping.TextIO | Noner   r    r   )r   s   "r   r   WSGITransport.__annotate__M   sF     ' '' #' 	'
 ' *' 
'r   c                	B    Wn         W n        W0n        W@n        WPn        R # r   )r9   r:   r<   r>   r?   )r'   r9   r:   r<   r>   r?   s   &&&&&&r   r(   WSGITransport.__init__M   s!     $8!&&&r   c                    V ^8  d   QhRRRR/# )r   requestr   r   r   r   )r   s   "r   r   r@   [   s     :E :Eg :E( :Er   c                	  aaa VP                  4        \        P                  ! VP                  4      pVP                  P
                  ;'       g"    R ^PRR/VP                  P                  ,          pRRRVP                  P                  RTRV P                  ;'       g    \        P                  RRR	R
RR
RVP                  RV P                  RVP                  P                  RVP                  P                  P                  R4      RVP                  P                  R\!        V4      RRRV P"                  /pVP$                  P&                   FW  w  rVVP                  R4      P)                  4       P+                  RR4      pVR9  d
   RV,           pVP                  R4      WG&   KY  	  RoRoRoRR VVV3R lllpV P-                  WH4      p	\/        V	4      p
Sf   Q hSf   Q hS'       d+   S^ ,          '       d   V P0                  '       d
   S^,          h\3        SP5                  4       ^ ,          4      pS UUu. uF'  w  r|VP7                  R4      VP7                  R4      3NK)  	  ppp\9        WV
R7      # u uppi ) httphttpsi  zwsgi.versionzwsgi.url_schemez
wsgi.inputzwsgi.errorszwsgi.multithreadTzwsgi.multiprocessFzwsgi.run_onceREQUEST_METHODSCRIPT_NAME	PATH_INFOQUERY_STRINGasciiSERVER_NAMESERVER_PORTSERVER_PROTOCOLzHTTP/1.1REMOTE_ADDR-_HTTP_Nc               (    V ^8  d   QhRRRRRRRR/# )	r   statusr=   response_headerszlist[tuple[str, str]]exc_infozOptExcInfo | Noner   z$typing.Callable[[bytes], typing.Any]r   )r   s   "r   r   2WSGITransport.handle_request.<locals>.__annotate__{   s0     		" 		"		"3		" (		" 2			"r   c                   < V oVoVoR  # )c                    R # r   r   )rR   s   &r   <lambda>FWSGITransport.handle_request.<locals>.start_response.<locals>.<lambda>   s    Tr   r   )rU   rV   rW   seen_exc_infoseen_response_headersseen_statuss   &&&r   start_response4WSGITransport.handle_request.<locals>.start_response{   s     !K$4!$M!!r   )headersstream)   r   )CONTENT_TYPECONTENT_LENGTHr   )readioBytesIOcontenturlportschemer?   sysstderrmethodr<   pathquerydecodehostr=   r>   rb   rawupperreplacer9   r   r:   intsplitencoder   )r'   rD   
wsgi_inputrl   environ
header_keyheader_valuekeyr`   r   rc   status_codevaluerb   r]   r^   r_   s   &&            @@@r   handle_requestWSGITransport.handle_request[   s3   ZZ0
{{QQFB#=gkk>P>P#QFw{{11*4++99szzUgnn4++))GKK--44W=7;;++3t9z4++
" )0(;(;$J##G,224<<S#FC<<m'..w7GL	 )<  $		" 		" '2'&&&$000]1--$2K2K2K""+++-a01 4
3
 ZZ %,,w"783 	 

 VDD
s   >-I;)r9   r:   r>   r<   r?   )T z	127.0.0.1N)r2   r3   r4   r5   __doc__r(   r   r6   r   r   r   r   r   ,   s    @':E :Er   )
__future__r   rh   r   rn   typing_modelsr   r   _typesr   baser   TYPE_CHECKING	_typeshedr   _typeshed.wsgir	   TypeVarr
   __all__r   r   r   r   r   r   <module>r      sh    " 	  
  ' # 	$.^^D 
^ iEM iEr   