Ë
    >Øïi5  ã                   óú  — d 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ej                  j                  dk(  Ze Z ej                  d«      Z ej                  «       dk(  Z ej                  «       dk(  Z ej                  «       dk(  Z ej&                  defi «      Zej                  dd d	k  rej,                  ZneZ	 ej2                  ZerCdd
lmZmZ m!Z!m"Z#m$Z$ ddl%m&Z& e'fZ(e'e)fZ*e+Z,e'Z-d„ Z.d„ Z/d„ Z0d„ Z1d„ Z2d„ Z3 G d„ de4«      Z5d„ Z6d„ Z7n]ddl8mZmZ m!Z! ddl$m"Z#m$Z$ ddl&m&Z& e(Z(e(Z*e,Z,e9Z-e:jv                  Z/e:jx                  Z0e:jz                  Z1e:j|                  Z2e?Z3e5Z5d„ Z.d„ Z6d„ Z7d„ Z@d„ ZAd„ ZBej†                  dk(  ZDej                  dd dk  ZEdZF ej                  «       dk(  r eB ejŽ                  «       «      ZFd ZHd!ZIej”                  ej–                  dfd"„ZLy# e$ r ej6                  ZY �Œ-w xY w)#zPThe compat module provides various Python 2 / Python 3
compatibility functions

é    Né   z(\d+).+ÚLinuxÚDarwinÚWindowsÚAbstractBase)é   r   )ÚquoteÚunquoteÚ	urlencodeÚparse_qsÚurlparse)ÚStringIOc                  ó*   — t        j                  «       S )z2
        Python 3 supports monotonic time
        )ÚtimeÚ	monotonic© ó    úE/var/www/html/aiagents/fe/lib/python3.12/site-packages/pika/compat.pyÚtime_nowr   9   s   € ô �~‰~ÓÐr   c                 ó4   — t        | j                  «       «      S )a   
        Returns a list of keys of dictionary

        dict.keys returns a view that works like .keys in Python 2
        *except* any modifications in the dictionary will be visible
        (and will cause errors if the view is being iterated over while
        it is modified).
        )ÚlistÚkeys©Údcts    r   Údictkeysr   ?   s   € ô �C—H‘H“JÓÐr   c                 ó4   — t        | j                  «       «      S )a(  
        Returns a list of values of a dictionary

        dict.values returns a view that works like .values in Python 2
        *except* any modifications in the dictionary will be visible
        (and will cause errors if the view is being iterated over while
        it is modified).
        )r   Úvaluesr   s    r   Ú
dictvaluesr   K   s   € ô �C—J‘J“LÓ!Ð!r   c                 ó"   — | j                  «       S )a<  
        Returns an iterator of items (key/value pairs) of a dictionary

        dict.items returns a view that works like .items in Python 2
        *except* any modifications in the dictionary will be visible
        (and will cause errors if the view is being iterated over while
        it is modified).
        )Úitemsr   s    r   Údict_iteritemsr!   V   s   € ð �y‰y‹{Ðr   c                 ó"   — | j                  «       S )zw
        :param dict dct:
        :returns: an iterator of the values of a dictionary
        :rtype: iterator
        )r   r   s    r   Údict_itervaluesr#   a   s   € ð �z‰z‹|Ðr   c                  ó   — t        | «      S )a  
        This is the same as Python 2 `chr(n)` for bytes in Python 3

        Returns a single byte `bytes` for the given int argument (we
        optimize it a bit here by passing the positional argument tuple
        directly to the bytes constructor.
        )Úbytes)Úargss    r   Úbyter'   i   s   € ô �T‹{Ðr   c                   ó   — e Zd ZdZd„ Zd„ Zy)Úlongzy
        A marker class that signifies that the integer value should be
        serialized as `l` instead of `I`
        c                 ó*   — t        t        | «      «      S )N)ÚstrÚint©Úselfs    r   Ú__str__zlong.__str__y   s   € Ü”s˜4“y“>Ð!r   c                 ó   — t        | «      dz   S )NÚL©r+   r-   s    r   Ú__repr__zlong.__repr__|   s   € Ü�t“9˜s‘?Ð"r   N)Ú__name__Ú
__module__Ú__qualname__Ú__doc__r/   r3   r   r   r   r)   r)   s   s   „ ñ	ò
	"ó	#r   r)   c                 ó   — t        | «      S )zs
        Return the canonical str value for the string.
        In both Python 3 and Python 2 this is str.
        r2   ©Úvalues    r   Úcanonical_strr;      s   € ô �5‹zÐr   c                 ó"   — t        | t        «      S ©z&
        Is value an integer?
        )Ú
isinstancer,   r9   s    r   Ú
is_integerr?   ‡   s   € ô ˜%¤Ó%Ð%r   )r	   r
   r   )r   r   c                  ó*   — t        j                   «       S )z:
        Python 2 does not support monotonic time
        )r   r   r   r   r   r   œ   s   € ô �y‰y‹{Ðr   c                 ól   — 	 t        | «      S # t        $ r t        | j                  d«      «      cY S w xY w)zÆ
        Returns the canonical string value of the given string.
        In Python 2 this is the value unchanged if it is an str, otherwise
        it is the unicode value encoded as UTF-8.
        zutf-8)r+   ÚUnicodeEncodeErrorÚencoder9   s    r   r;   r;   ¢   s4   € ð	.Ü�u“:ÐøÜ!ò 	.Ü�u—|‘| GÓ,Ó-Ò-ð	.ús   ‚
 �#3²3c                 ó.   — t        | t        t        f«      S r=   )r>   r,   r)   r9   s    r   r?   r?   ®   s   € ô ˜%¤#¤t Ó-Ð-r   c                 óH   — t        | t        «      s| j                  d«      S | S )z 
    Returns value as bytes
    zUTF-8)r>   r%   rC   r9   s    r   Úas_bytesrF   µ   s"   € ô �eœUÔ#Ø�|‰|˜GÓ$Ð$Ø€Lr   c                 ó¢   — | j                  «       rt        | «      S t        j                  | «      }|rt        |j	                  «       d   «      S dS )z%
    Returns value as in integer
    r   )Úisdigitr,   ÚRE_NUMÚmatchÚgroups)r:   rJ   s     r   Úto_digitrL   ¾   sB   € ð ‡}�}„Ü�5‹zÐÜ�L‰L˜Ó€EÙ%*Œ3ˆu�|‰|‹~˜aÑ Ó!Ð1°Ð1r   c                 ó€   — | j                  d«      d   }t        t        t        |j                  d«      dd «      «      S )z
    Gets linux version
    ú-r   ú.Nr   )ÚsplitÚtupleÚmaprL   )Úrelease_strÚver_strs     r   Úget_linux_versionrU   È   s;   € ð ×Ñ Ó$ QÑ'€GÜ””X˜wŸ}™}¨SÓ1°"°1Ð5Ó6Ó7Ð7r   Úposix)r   é   z	127.0.0.1z::1c                 ó   — | t         j                  k(  rt        }n%| t         j                  k(  rt        }nt        d«      ‚|t         j                  k7  rt        d«      ‚|dk7  rt        d«      ‚t        j                   | ||«      }	 |j                  |df«       |j                  t        t         j                  d«      «       |j                  «       dd \  }}t        j                   | ||«      }	 |j                  ||f«       |j                  «       \  }}		 |j                  «        |j!                  d«       |j!                  d«       ||fS # t        $ r |j                  «        ‚ w xY w# |j                  «        w xY w)	zÄ
    Returns a pair of sockets in the manner of socketpair with the additional
    feature that they will be non-blocking. Prior to Python 3.5, socketpair
    did not exist on Windows at all.
    z?Only AF_INET and AF_INET6 socket address families are supportedz0Only SOCK_STREAM socket socket_type is supportedr   zOnly protocol zero is supportedé€   Nr   F)ÚsocketÚAF_INETÚ
_LOCALHOSTÚAF_INET6Ú_LOCALHOST_V6Ú
ValueErrorÚSOCK_STREAMÚbindÚlistenÚminÚ	SOMAXCONNÚgetsocknameÚconnectÚacceptÚ	ExceptionÚcloseÚsetblocking)
ÚfamilyÚsocket_typeÚprotoÚhostÚlsockÚaddrÚportÚcsockÚssockÚ_s
             r   Ú_nonblocking_socketpairru   Ü   sP  € ð ”—‘ÒÜ‰Ø	”6—?‘?Ò	"Ü‰äð )ó *ð 	*à”f×(Ñ(Ò(ÜÐKÓLÐLØ�‚zÜÐ:Ó;Ð;ä�M‰M˜& +¨uÓ5€EðØ�
‰
�D˜!�9ÔØ�‰”Sœ×)Ñ)¨3Ó/Ô0à×&Ñ&Ó(¨¨!Ð,‰
ˆˆdÜ—‘˜f k°5Ó9ˆð	Ø�M‰M˜4 ˜,Ô'Ø—|‘|“~‰HˆE‘1ð
 	�‰Œð 
×Ñ�eÔØ	×Ñ�eÔà�%ˆ<Ðøô ò 	Ø�K‰KŒMØð	ûð 	�‰�ús   ÂA)E+ Ã0&E ÅE(Å(E+ Å+E=)Mr7   ÚabcÚosÚplatformÚrerZ   ÚsysÚ_sysr   Úversion_infoÚmajorÚPY2ÚPY3ÚcompilerI   ÚsystemÚON_LINUXÚON_OSXÚ
ON_WINDOWSÚABCMetaÚobjectr   ÚerrorÚSOCKET_ERRORÚOSErrorÚSOL_TCPÚAttributeErrorÚIPPROTO_TCPÚurllib.parser	   Ú	url_quoter
   Úurl_unquoter   r   Úurl_parse_qsr   Úior   r+   Ú
basestringr%   Ústr_or_bytesÚrangeÚxrangeÚunicode_typer   r   r   r!   r#   r'   r,   r)   r;   r?   ÚurllibÚunicodeÚdictr   r   Ú	iteritemsÚ
itervaluesÚchrrF   rL   rU   ÚnameÚHAVE_SIGNALÚEINTR_IS_EXPOSEDÚLINUX_VERSIONÚreleaser\   r^   r[   r`   ru   r   r   r   ú<module>r¢      s@  ðñó Û 	Û Û 	Û Û Û à
×Ñ×Ñ Ñ"€Ø
€g€Ø	ˆ�‰�JÓ	€àˆ8�?‰?Ó Ñ'€Ø	ˆ�‰Ó	˜hÑ	&€ØˆX�_‰_Ó )Ñ+€
ð ˆs�{‰{˜>¨F¨9°bÓ9€à×Ñ�R�aÐ˜6Ò!Ø—<‘<�Lð €Lð!Ø�n‰n€Gñ ÷Mõ Måð �€Jð ˜�<€Lð €Fð €Lò ò
 ò	"ò	òòô
#ˆsô 
#òó&÷ OÑNß=Ý!à€JØ€LØ€FØ€LØ�y‰y€HØ—‘€JØ—^‘^€NØ—o‘o€OØ€DØ€Dòò
.ò.òò2ò8ð �g‰g˜Ñ €à×$Ñ$ R aÐ(¨FÑ2Ð à€Ø€8‡?�?Ó˜ÒÙ%Ð&6 h×&6Ñ&6Ó&8Ó9€Mà€
Ø€ð $*§>¡>Ø(.×(:Ñ(:Ø"#ô)øðu ò !Ø× Ñ ƒGð!ús   Ã G% Ç%G:Ç9G: