HEX
Server: Apache
System: Linux p102.lithium.hosting 4.18.0-553.141.1.el8_10.x86_64 #1 SMP Fri Jul 10 17:48:02 UTC 2026 x86_64
User: bvzmoamr (9955)
PHP: 8.1.34
Disabled: syslog
Upload Files
File: //proc/self/root/lib64/python2.7/site-packages/mercurial/wireprototypes.pyo
�
1�3\c@@s�ddlmZddlmZmZddlmZddlmZddl	m
Z
mZddlm
Z
dZd	Zd
ZdZdZiid
d6dd6e6id
d6dd6e6idd6dd6d6idd6dd6e6Zdefd��YZdefd��YZdefd��YZdefd��YZdefd��YZdefd��YZdd �Zdd!�Zd"�Zd#�Zi
d$d%6d&d'6d$d(6d&d)6d&d*6d+d,6d-d.6d&d/6d&d06d&d16Zd2e
j fd3��YZ!d4efd5��YZ"d6e#fd7��YZ$d8�Z%ej&d9efd:��Y�Z'ej&d;efd<��Y�Z(ej&d=efd>��Y�Z)d?S(@i(tabsolute_importi(tbinthex(t_(tattr(terrortutil(t
interfaceutilsssh-v1sexp-ssh-v2-0003sexp-http-v2-0003sexp-narrow-1sexp-ellipses-1tssht	transporttversionthttpshttp-v1it
bytesresponsecB@seZdZd�ZRS(s1A wire protocol response consisting of raw bytes.cC@s
||_dS(N(tdata(tselfR
((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt__init__9s(t__name__t
__module__t__doc__R(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR7stooberrorcB@seZdZd�ZRS(s�wireproto reply: failure of a batch of operation

    Something failed during a batch call. The error message is stored in
    `self.message`.
    cC@s
||_dS(N(tmessage(RR((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRBs(RRRR(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR<stpushrescB@seZdZd�ZRS(s�wireproto reply: success with simple integer return

    The call was successful and returned an integer contained in `self.res`.
    cC@s||_||_dS(N(trestoutput(RRR((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRJs	(RRRR(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyREstpusherrcB@seZdZd�ZRS(shwireproto reply: failure

    The call failed. The `self.res` attribute contains the error message.
    cC@s||_||_dS(N(RR(RRR((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRSs	(RRRR(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRNst	streamrescB@seZdZded�ZRS(sEwireproto reply: binary stream

    The call was successful and the result is a stream.

    Accepts a generator containing chunks of data to be sent to the client.

    ``prefer_uncompressed`` indicates that the data is expected to be
    uncompressable and that the stream should therefore use the ``none``
    engine.
    cC@s||_||_dS(N(tgentprefer_uncompressed(RRR((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRbs	N(RRRtNonetFalseR(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRWs
tstreamreslegacycB@seZdZdd�ZRS(s:wireproto reply: uncompressed binary stream

    The call was successful and the result is a stream.

    Accepts a generator containing chunks of data to be sent to the client.

    Like ``streamres``, but sends an uncompressed data for "version 1" clients
    using the application/mercurial-0.1 media type.
    cC@s
||_dS(N(R(RR((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRpsN(RRRRR(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRfs	t cC@s0|r,g|j|�D]}t|�^qSgS(N(tsplitR(tltseptv((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt
decodelistts&cC@s5y|jtt|��SWntk
r0�nXdS(N(tjointmapRt	TypeError(R!R"((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt
encodelistys
cC@s4|jdd�jdd�jdd�jdd�S(	Nt:s:ct,s:ot;s:st=s:e(treplace(tplain((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytescapebatcharg�s
cC@s4|jdd�jdd�jdd�jdd�S(	Ns:eR,s:sR+s:oR*s:cR)(R-(tescaped((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytunescapebatcharg�s
tnodestheadstbooleant	bookmarkstcommont
obsmarkerstphasestscsvt
bundlecapstcsvtlistkeystcgtcbattemptedtstreamtbaseprotocolhandlercB@s\eZdZejd�Zd�Zd�Zd�Zd�Z	d�Z
d�Zd�ZRS(	sFAbstract base class for wire protocol handlers.

    A wire protocol handler serves as an interface between protocol command
    handlers and the wire protocol transport layer. Protocol handlers provide
    methods to read command arguments, redirect stdio for the duration of
    the request, handle response types, etc.
    slThe name of the protocol implementation.

        Used for uniquely identifying the transport type.
        cC@sdS(s�return the value for arguments in <args>

        For version 1 transports, returns a list of values in the same
        order they appear in ``args``. For version 2 transports, returns
        a dict mapping argument name to value.
        N((targs((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytgetargs�tcC@sdS(s�Returns the list of protocol-level capabilities of client

        Returns a list of capabilities as declared by the client for
        the current request (or connection for stateful protocol handlers).N((((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytgetprotocaps�RCcC@sdS(s�Provide a generator for the raw payload.

        The caller is responsible for ensuring that the full payload is
        processed.
        N((((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt
getpayload�RCcC@sdS(s�Context manager to possibly redirect stdio.

        The context manager yields a file-object like object that receives
        stdout and stderr output when the context manager is active. Or it
        yields ``None`` if no I/O redirection occurs.

        The intent of this context manager is to capture stdio output
        so it may be sent in the response. Some transports support streaming
        stdio to the client in real time. For these transports, stdio output
        won't be captured.
        N((((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytmayberedirectstdio�RCcC@sdS(s:Returns a string representation of this client (as bytes).N((((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytclient�RCcC@sdS(s�Adds advertised capabilities specific to this protocol.

        Receives the list of capabilities collected so far.

        Returns a list of capabilities. The passed in argument can be returned.
        N((trepotcaps((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytaddcapabilities�RCcC@sdS(sValidate that the client has permissions to perform a request.

        The argument is the permission required to proceed. If the client
        doesn't have that permission, the exception should raise or abort
        in a protocol specific manner.
        N((tperm((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt	checkperm�RC(
RRRRt	AttributetnameRBRDRERFRGRJRL(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR@�s					
		tcommandentrycB@sAeZdZdddddd�Zd�Zd�Zd�ZRS(s,Represents a declared wire protocol command.RCtpushcC@sC||_||_|pt�|_||_||_||_dS(N(tfuncRAtsett
transportst
permissiont
cachekeyfntextracapabilitiesfn(RRQRARSRTRURV((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR�s				cC@s(t|d|dt|j�d|j�S(s<Merge this instance with an incoming 2-tuple.

        This is called when a caller using the old 2-tuple API attempts
        to replace an instance. The incoming values are merged with
        data not captured by the 2-tuple and a new instance containing
        the union of the two objects is returned.
        RARSRT(RORRRSRT(RRQRA((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt_merge�scc@s|jV|jVdS(N(RQRA(R((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt__iter__scC@s6|dkr|jS|dkr&|jStd��dS(Niis can only access elements 0 and 1(RQRAt
IndexError(Rti((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt__getitem__s
N(RRRRRRWRXR[(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRO�s		tcommanddictcB@s eZdZd�Zd�ZRS(s�Container for registered wire protocol commands.

    It behaves like a dict. But __setitem__ is overwritten to allow silent
    coercion of values from 2-tuples for API compatibility.
    cC@s�t|t�rn�t|t�r�t|�dkrBtd��n||kro||j|d|d�}q�t|dd|ddtt�dd�}ntd	��tt	|�j
||�S(
Nis+command tuples must have exactly 2 elementsiiRARSRTRPs:command entries must be commandentry instances or 2-tuples(t
isinstanceROttupletlent
ValueErrorRWRRt
TRANSPORTStsuperR\t__setitem__(RtkR#((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyRcs!cC@s3|j|�}|stS|j|jkr/tStS(s?Determine if a command is available for the requested protocol.(tgetRRNRStTrue(Rtcommandtprototentry((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytcommandavailable-s(RRRRcRj(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR\s	c@s�tjj|�}|tjkr<|jdd��d}n|jdd��d}�s�|tjkrodnd}g|D]'}t|j�|�d	kr||^q|Std
�|D���t�fd��D��}|rtj	t
d�|d
jt|��f��ng|D]}|j
��kr|^q}t|d�fd��}|s�tj	t
d�|dt
d�d
j����n|S(s?Obtain the list of supported compression engines for a request.tservertcompressionenginessserver.compressionenginestexperimentaltclientcompressionenginess%experimental.clientcompressionenginestserverprioritytclientpriorityics@s|]}|j�VqdS(N(RN(t.0te((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pys	<genexpr>Zsc3@s!|]}|�kr|VqdS(N((RqRr(t
validnames(s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pys	<genexpr>[ss,invalid compression engine defined in %s: %ss, tkeyc@s�j|j��S(N(tindexRN(Rr(t
configengines(s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt<lambda>bRCs?%s config option does not specify any known compression enginesthintsusable compression engines: %s(Rtcompenginestsupportedwireenginest
SERVERROLEt
configlisttgetattrtwireprotosupportRRRtAbortRR%tsortedRN(tuitroleRytconfigRRrtinvalidnames((RvRss>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pytsupportedcompengines;s2			
%"+		tencodedresponsecB@seZdZej�ZRS(s7Represents response data that is already content encoded.

    Wire protocol version 2 only.

    Commands typically emit Python objects that are encoded and sent over the
    wire. If commands emit an object of this type, the encoding step is bypassed
    and the content from this object is used instead.
    (RRRRtibR
(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR�ls	talternatelocationresponsecB@s�eZdZej�Zej�Zejdd�Zejdd�Z	ejdd�Z
ejdd�Zejdd�ZRS(s�Represents a response available at an alternate location.

    Instances are sent in place of actual response objects when the server
    is sending a "content redirect" response.

    Only compatible with wire protocol version 2.
    tdefaultN(
RRRRR�turlt	mediatypeRtsizet
fullhashestfullhashseedtserverdercertstservercadercerts(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR�xstindefinitebytestringresponsecB@seZdZej�ZRS(s�Represents an object to be encoded to an indefinite length bytestring.

    Instances are initialized from an iterable of chunks, with each chunk being
    a bytes instance.
    (RRRRR�tchunks(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyR��sN(*t
__future__RtnodeRRti18nRt
thirdpartyRRCRRtutilsRtSSHV1tSSHV2tHTTP_WIREPROTO_V2t	NARROWCAPtELLIPSESCAPRatobjectRRRRRRR$R(R/R1tGETBUNDLE_ARGUMENTSt	InterfaceR@ROtdictR\R�tsR�R�R�(((s>/usr/lib64/python2.7/site-packages/mercurial/wireprototypes.pyt<module>sl					
D#-	1