Plan 9 from Bell Labs’s /usr/web/sources/contrib/stallion/root/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pyc

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


�
��	@s�ddkZddkZddkZddkZddklZlZddklZdZ	dZ
defd��YZd�Z
d	�ZdS(
i�N(tutilt	wireproto(tHTTP_OKsapplication/mercurial-0.1sapplication/hg-errortwebprotocBsPeZd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Z	RS(cCs||_d|_||_dS(Nt(treqtresponsetui(tselfRR((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pyt__init__s		c	Cs�|i�}h}|i�}x�|D]�}|djo[h}xD|i�D]6}|djo#||jo||d||<qKqKW||d<q%||d||<q%Wg}|D]}|||q�~S(Nt*tcmdi(t_argstsplittkeys(	Rtargst	knownargstdataRtktstartkeyt_[1]((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytgetargss

cCs�|iii�}g}d}xTtoL|iiidt|��}|djoPn||g7}|d7}q!W|it	i
di|�dt��|S(Nit
HTTP_X_HGARG_Rtkeep_blank_values(RtformtcopytTruetenvtgettstrtNonetupdatetcgitparse_qstjoin(RRtchunkstith((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pyR"s


%cCsJt|iid�}x-ti|id|�D]}|i|�q/WdS(NtCONTENT_LENGTHtlimit(tintRRRt
filechunkitertwrite(Rtfptlengthts((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytgetfile.scCs;|ii|iif|_ti�|i_|i_dS(N(Rtfouttferrtoldiot	cStringIOtStringIO(R((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytredirect2scCs1|iii�}|i\|i_|i_|S(N(RR0tgetvalueR2R1(Rtval((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytrestore5sccsSti�}x5to-|id�}|pPn|i|�VqW|i�VdS(Ni(tzlibtcompressobjRtreadtcompresstflush(Rtcgtztchunk((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytgroupchunks9s
cCs]d|iiid�pdti|iiidd��ti|iiidd��fS(Nsremote:%s:%s:%sswsgi.url_schemethttptREMOTE_HOSTRtREMOTE_USER(RRRturllibtquote(R((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pyt_clientAs(
t__name__t
__module__R	RRR/R5R8RARG(((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pyRs							cCs
|tijS(N(Rtcommands(R((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytiscmdGscCsut||i�}ti|||�}t|t�o'|ittdt	|��|gSnt|ti
�o|itt�|iSn�t|ti�o4|i
�}|itt�d|i|fgSn�t|ti�oH|i�|i
�d|i}|ittdt	|��|gSnDt|ti�o0|i}|ittdt	|��|gSndS(NR-s%d
%ss0
%s
(RRRtdispatcht
isinstanceRtrespondRtHGTYPEtlent	streamrestgentpushresR8trestpusherrtdraintooberrortmessaget	HGERRTYPE(trepoRRtptrspR7((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pytcallJs,


	(R!R3R9REt	mercurialRRtcommonRRORYtobjectRRKR](((sG/sys/lib/python/lib/python2.5/site-packages/mercurial/hgweb/protocol.pys<module>s08	

Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.