shell bypass 403

Cubjrnet7 Shell


name : specifiers.cpython-39.opt-1.pyc
a

?&Nb�}�@s\ddlmZmZmZddlZddlZddlZddlZddlZddl	m
Z
mZddlm
Z
ddlmZddlmZmZmZe
r�ddlmZmZmZmZmZmZmZmZeeefZeeeefZeeege fZ!Gd	d
�d
e"�Z#Gdd�deej$e%��Z&Gd
d�de&�Z'Gdd�de'�Z(dd�Z)Gdd�de'�Z*e�+d�Z,dd�Z-dd�Z.Gdd�de&�Z/dS)�)�absolute_import�division�print_functionN�)�string_types�with_metaclass)�
TYPE_CHECKING)�canonicalize_version)�
LegacyVersion�Version�parse)�Callable�Dict�Iterable�Iterator�List�Optional�Tuple�Unionc@seZdZdZdS)�InvalidSpecifierzH
    An invalid specifier was found, users should refer to PEP 440.
    N)�__name__�
__module__�__qualname__�__doc__�rr�8/usr/lib/python3.9/site-packages/packaging/specifiers.pyrsrc@s�eZdZejdd��Zejdd��Zejdd��Zejdd��Zej	d	d
��Z
e
jdd
��Z
ejdd
d��Zejddd��Z
dS)�
BaseSpecifiercCsdS)z�
        Returns the str representation of this Specifier like object. This
        should be representative of the Specifier itself.
        Nr��selfrrr�__str__ szBaseSpecifier.__str__cCsdS)zF
        Returns a hash value for this Specifier like object.
        Nrrrrr�__hash__(szBaseSpecifier.__hash__cCsdS)zq
        Returns a boolean representing whether or not the two Specifier like
        objects are equal.
        Nr�r�otherrrr�__eq__/szBaseSpecifier.__eq__cCsdS)zu
        Returns a boolean representing whether or not the two Specifier like
        objects are not equal.
        Nrr!rrr�__ne__7szBaseSpecifier.__ne__cCsdS)zg
        Returns whether or not pre-releases as a whole are allowed by this
        specifier.
        Nrrrrr�prereleases?szBaseSpecifier.prereleasescCsdS)zd
        Sets whether or not pre-releases as a whole are allowed by this
        specifier.
        Nr�r�valuerrrr%GsNcCsdS)zR
        Determines if the given item is contained within this specifier.
        Nr�r�itemr%rrr�containsOszBaseSpecifier.containscCsdS)z�
        Takes an iterable of items and filters them so that only items which
        are contained within this specifier are allowed in it.
        Nr)r�iterabler%rrr�filterVszBaseSpecifier.filter)N)N)rrr�abc�abstractmethodrr r#r$�abstractpropertyr%�setterr*r,rrrrrs 





rc@s�eZdZiZd"dd�Zdd�Zdd�Zed	d
��Zdd�Z	d
d�Z
dd�Zdd�Zdd�Z
edd��Zedd��Zedd��Zejdd��Zdd�Zd#dd�Zd$d d!�ZdS)%�_IndividualSpecifier�NcCsF|j�|�}|std�|���|�d���|�d���f|_||_dS)NzInvalid specifier: '{0}'�operator�version)�_regex�searchr�format�group�strip�_spec�_prereleases)r�specr%�matchrrr�__init__cs�z_IndividualSpecifier.__init__cCs0|jdurd�|j�nd}d�|jjt|�|�S)N�, prereleases={0!r}r2z<{0}({1!r}{2})>)r;r7r%�	__class__r�str�rZprerrr�__repr__qs
��z_IndividualSpecifier.__repr__cCsdj|j�S)Nz{0}{1})r7r:rrrrr{sz_IndividualSpecifier.__str__cCs|jdt|jd�fS)Nrr)r:r	rrrr�_canonical_specsz$_IndividualSpecifier._canonical_speccCs
t|j�S�N)�hashrDrrrrr �sz_IndividualSpecifier.__hash__cCsRt|t�r6z|�t|��}WqFty2tYS0nt||j�sFtS|j|jkSrE)�
isinstancerr@rAr�NotImplementedrDr!rrrr#�s
z_IndividualSpecifier.__eq__cCsRt|t�r6z|�t|��}WqFty2tYS0nt||j�sFtS|j|jkSrE)rGrr@rArrHr:r!rrrr$�s
z_IndividualSpecifier.__ne__cCst|d�|j|��}|S)Nz_compare_{0})�getattrr7�
_operators)r�op�operator_callablerrr�
_get_operator�s�z"_IndividualSpecifier._get_operatorcCst|ttf�st|�}|SrE)rGr
rr�rr4rrr�_coerce_version�sz$_IndividualSpecifier._coerce_versioncCs
|jdS)Nr�r:rrrrr3�sz_IndividualSpecifier.operatorcCs
|jdS)NrrPrrrrr4�sz_IndividualSpecifier.versioncCs|jSrE�r;rrrrr%�sz _IndividualSpecifier.prereleasescCs
||_dSrErQr&rrrr%�scCs
|�|�SrE�r*�rr)rrr�__contains__�sz!_IndividualSpecifier.__contains__cCs>|dur|j}|�|�}|jr&|s&dS|�|j�}|||j�S�NF)r%rO�
is_prereleaserMr3r4)rr)r%Znormalized_itemrLrrrr*�s

z_IndividualSpecifier.containsccs�d}g}d|dur|ndi}|D]F}|�|�}|j|fi|��r |jr\|s\|js\|�|�q d}|Vq |s�|r�|D]
}|VqtdS)NFr%T)rOr*rVr%�append)rr+r%�yielded�found_prereleases�kwr4�parsed_versionrrrr,�s"
��z_IndividualSpecifier.filter)r2N)N)N)rrrrJr>rCr�propertyrDr r#r$rMrOr3r4r%r0rTr*r,rrrrr1_s,







r1cs�eZdZdZe�dedejejB�Zdddddd	d
�Z	d�fd
d�	Z
dd�Zdd�Zdd�Z
dd�Zdd�Zdd�Zdd�Z�ZS)�LegacySpecifiera�
        (?P<operator>(==|!=|<=|>=|<|>))
        \s*
        (?P<version>
            [^,;\s)]* # Since this is a "legacy" specifier, and the version
                      # string can be just about anything, we match everything
                      # except for whitespace, a semi-colon for marker support,
                      # a closing paren since versions can be enclosed in
                      # them, and a comma since it's a version separator.
        )
        �^\s*�\s*$�equal�	not_equal�less_than_equal�greater_than_equal�	less_than�greater_than)�==�!=�<=�>=�<�>r2Ncs"tt|��||�t�dt�dS)NzZCreating a LegacyVersion has been deprecated and will be removed in the next major release)�superr]r>�warnings�warn�DeprecationWarning)rr<r%�r@rrr>s
�zLegacySpecifier.__init__cCst|t�stt|��}|SrE)rGr
rArNrrrrO!s
zLegacySpecifier._coerce_versioncCs||�|�kSrE�rO�r�prospectiver<rrr�_compare_equal'szLegacySpecifier._compare_equalcCs||�|�kSrErqrrrrr�_compare_not_equal+sz"LegacySpecifier._compare_not_equalcCs||�|�kSrErqrrrrr�_compare_less_than_equal/sz(LegacySpecifier._compare_less_than_equalcCs||�|�kSrErqrrrrr�_compare_greater_than_equal3sz+LegacySpecifier._compare_greater_than_equalcCs||�|�kSrErqrrrrr�_compare_less_than7sz"LegacySpecifier._compare_less_thancCs||�|�kSrErqrrrrr�_compare_greater_than;sz%LegacySpecifier._compare_greater_than)r2N)rrr�
_regex_str�re�compile�VERBOSE�
IGNORECASEr5rJr>rOrtrurvrwrxry�
__classcell__rrrprr]�s"�	
r]cst����fdd��}|S)Ncst|t�sdS�|||�SrU)rGrrr��fnrr�wrappedDs
z)_require_version_compare.<locals>.wrapped)�	functools�wraps)r�r�rr�r�_require_version_compare@sr�c	@s�eZdZdZe�dedejejB�Zdddddd	d
dd�Z	e
d
d��Ze
dd��Ze
dd��Z
e
dd��Ze
dd��Ze
dd��Ze
dd��Zdd�Zedd��Zejdd��Zd S)!�	Specifiera
        (?P<operator>(~=|==|!=|<=|>=|<|>|===))
        (?P<version>
            (?:
                # The identity operators allow for an escape hatch that will
                # do an exact string match of the version you wish to install.
                # This will not be parsed by PEP 440 and we cannot determine
                # any semantic meaning from it. This operator is discouraged
                # but included entirely as an escape hatch.
                (?<====)  # Only match for the identity operator
                \s*
                [^\s]*    # We just match everything, except for whitespace
                          # since we are only testing for strict identity.
            )
            |
            (?:
                # The (non)equality operators allow for wild card and local
                # versions to be specified so we have to define these two
                # operators separately to enable that.
                (?<===|!=)            # Only match for equals and not equals

                \s*
                v?
                (?:[0-9]+!)?          # epoch
                [0-9]+(?:\.[0-9]+)*   # release
                (?:                   # pre release
                    [-_\.]?
                    (a|b|c|rc|alpha|beta|pre|preview)
                    [-_\.]?
                    [0-9]*
                )?
                (?:                   # post release
                    (?:-[0-9]+)|(?:[-_\.]?(post|rev|r)[-_\.]?[0-9]*)
                )?

                # You cannot use a wild card and a dev or local version
                # together so group them with a | and make them optional.
                (?:
                    (?:[-_\.]?dev[-_\.]?[0-9]*)?         # dev release
                    (?:\+[a-z0-9]+(?:[-_\.][a-z0-9]+)*)? # local
                    |
                    \.\*  # Wild card syntax of .*
                )?
            )
            |
            (?:
                # The compatible operator requires at least two digits in the
                # release segment.
                (?<=~=)               # Only match for the compatible operator

                \s*
                v?
                (?:[0-9]+!)?          # epoch
                [0-9]+(?:\.[0-9]+)+   # release  (We have a + instead of a *)
                (?:                   # pre release
                    [-_\.]?
                    (a|b|c|rc|alpha|beta|pre|preview)
                    [-_\.]?
                    [0-9]*
                )?
                (?:                                   # post release
                    (?:-[0-9]+)|(?:[-_\.]?(post|rev|r)[-_\.]?[0-9]*)
                )?
                (?:[-_\.]?dev[-_\.]?[0-9]*)?          # dev release
            )
            |
            (?:
                # All other operators only allow a sub set of what the
                # (non)equality operators do. Specifically they do not allow
                # local versions to be specified nor do they allow the prefix
                # matching wild cards.
                (?<!==|!=|~=)         # We have special cases for these
                                      # operators so we want to make sure they
                                      # don't match here.

                \s*
                v?
                (?:[0-9]+!)?          # epoch
                [0-9]+(?:\.[0-9]+)*   # release
                (?:                   # pre release
                    [-_\.]?
                    (a|b|c|rc|alpha|beta|pre|preview)
                    [-_\.]?
                    [0-9]*
                )?
                (?:                                   # post release
                    (?:-[0-9]+)|(?:[-_\.]?(post|rev|r)[-_\.]?[0-9]*)
                )?
                (?:[-_\.]?dev[-_\.]?[0-9]*)?          # dev release
            )
        )
        r^r_Z
compatibler`rarbrcrdreZ	arbitrary)�~=rfrgrhrirjrk�===cCsNd�tt�dd�t|���dd��}|d7}|�d�||�oL|�d�||�S)N�.cSs|�d�o|�d�S)NZpost�dev)�
startswith��xrrr�<lambda>��z/Specifier._compare_compatible.<locals>.<lambda>����.*rirf)�join�list�	itertools�	takewhile�_version_splitrM)rrsr<�prefixrrr�_compare_compatible�s
����
�zSpecifier._compare_compatiblec	Csz|�d�rVt|j�}t|dd��}tt|��}|dt|��}t||�\}}||kSt|�}|jsnt|j�}||kSdS)Nr����)�endswithr�publicr�rA�len�_pad_version�local)	rrsr<Z
split_specZsplit_prospectiveZshortened_prospectiveZpadded_specZpadded_prospectiveZspec_versionrrrrt�s

�
zSpecifier._compare_equalcCs|�||�SrE)rtrrrrrruszSpecifier._compare_not_equalcCst|j�t|�kSrE�rr�rrrrrrvsz"Specifier._compare_less_than_equalcCst|j�t|�kSrEr�rrrrrrwsz%Specifier._compare_greater_than_equalcCs<t|�}||ksdS|js8|jr8t|j�t|j�kr8dSdS�NFT)rrV�base_version�rrsZspec_strr<rrrrxszSpecifier._compare_less_thancCs^t|�}||ksdS|js8|jr8t|j�t|j�kr8dS|jdurZt|j�t|j�krZdSdSr�)rZis_postreleaser�r�r�rrrry2s
zSpecifier._compare_greater_thancCst|���t|���kSrE)rA�lowerrrrrr�_compare_arbitrarySszSpecifier._compare_arbitrarycCsR|jdur|jS|j\}}|dvrN|dkr@|�d�r@|dd�}t|�jrNdSdS)N)rfrirhr�r�rfr�r�TF)r;r:r�rrV)rr3r4rrrr%Ws


zSpecifier.prereleasescCs
||_dSrErQr&rrrr%qsN)rrrrzr{r|r}r~r5rJr�r�rtrurvrwrxryr�r\r%r0rrrrr�Ns<]�

(




 
r�z^([0-9]+)((?:a|b|c|rc)[0-9]+)$cCs@g}|�d�D],}t�|�}|r0|�|���q|�|�q|S)Nr�)�split�
_prefix_regexr6�extend�groupsrW)r4�resultr)r=rrrr�zs
r�c
Cs�gg}}|�tt�dd�|���|�tt�dd�|���|�|t|d�d��|�|t|d�d��|�ddgtdt|d�t|d���|�ddgtdt|d�t|d���ttj|��ttj|��fS)NcSs|��SrE��isdigitr�rrrr��r�z_pad_version.<locals>.<lambda>cSs|��SrEr�r�rrrr��r�rr�0)rWr�r�r�r��insert�max�chain)�left�rightZ
left_splitZright_splitrrrr��s
,,r�c@s�eZdZddd�Zdd�Zdd�Zd	d
�Zdd�Zd
d�Zdd�Z	dd�Z
dd�Zedd��Z
e
jdd��Z
dd�Zddd�Zd dd�ZdS)!�SpecifierSetr2Nc	Csldd�|�d�D�}t�}|D]8}z|�t|��WqtyT|�t|��Yq0qt|�|_||_dS)NcSsg|]}|��r|���qSr)r9��.0�srrr�
<listcomp>�r�z)SpecifierSet.__init__.<locals>.<listcomp>�,)	r��set�addr�rr]�	frozenset�_specsr;)rZ
specifiersr%Zsplit_specifiers�parsed�	specifierrrrr>�s
zSpecifierSet.__init__cCs*|jdurd�|j�nd}d�t|�|�S)Nr?r2z<SpecifierSet({0!r}{1})>)r;r7r%rArBrrrrC�s
��zSpecifierSet.__repr__cCsd�tdd�|jD���S)Nr�css|]}t|�VqdSrE)rAr�rrr�	<genexpr>�r�z'SpecifierSet.__str__.<locals>.<genexpr>)r��sortedr�rrrrr�szSpecifierSet.__str__cCs
t|j�SrE)rFr�rrrrr �szSpecifierSet.__hash__cCs�t|t�rt|�}nt|t�s"tSt�}t|j|jB�|_|jdurX|jdurX|j|_n<|jdurv|jdurv|j|_n|j|jkr�|j|_ntd��|S)NzFCannot combine SpecifierSets with True and False prerelease overrides.)rGrr�rHr�r�r;�
ValueError)rr"r�rrr�__and__�s 





�zSpecifierSet.__and__cCs6t|ttf�rtt|��}nt|t�s*tS|j|jkSrE�rGrr1r�rArHr�r!rrrr#�s

zSpecifierSet.__eq__cCs6t|ttf�rtt|��}nt|t�s*tS|j|jkSrEr�r!rrrr$�s

zSpecifierSet.__ne__cCs
t|j�SrE)r�r�rrrr�__len__�szSpecifierSet.__len__cCs
t|j�SrE)�iterr�rrrr�__iter__�szSpecifierSet.__iter__cCs.|jdur|jS|jsdStdd�|jD��S)Ncss|]}|jVqdSrE�r%r�rrrr�r�z+SpecifierSet.prereleases.<locals>.<genexpr>)r;r��anyrrrrr%�s

zSpecifierSet.prereleasescCs
||_dSrErQr&rrrr%scCs
|�|�SrErRrSrrrrT
szSpecifierSet.__contains__csLt�ttf�st����dur$|j��s2�jr2dSt��fdd�|jD��S)NFc3s|]}|j��d�VqdS)r�NrRr��r)r%rrr�+r�z(SpecifierSet.contains.<locals>.<genexpr>)rGr
rrr%rV�allr�r(rr�rr*s
zSpecifierSet.containscCs�|dur|j}|jr6|jD]}|j|t|�d�}q|Sg}g}|D]P}t|ttf�s^t|�}n|}t|t�rnqB|jr�|s�|s�|�	|�qB|�	|�qB|s�|r�|dur�|S|SdS)Nr�)
r%r�r,�boolrGr
rrrVrW)rr+r%r<ZfilteredrYr)r[rrrr,-s*




zSpecifierSet.filter)r2N)N)N)rrrr>rCrr r�r#r$r�r�r\r%r0rTr*r,rrrrr��s"

		


�r�)0Z
__future__rrrr-r�r�r{rmZ_compatrrZ_typingrZutilsr	r4r
rr�typingr
rrrrrrrZ
ParsedVersionrAZUnparsedVersionr�ZCallableOperatorr�r�ABCMeta�objectrr1r]r�r�r|r�r�r�r�rrrr�<module>s6(@ B+


© 2025 Cubjrnet7