Server IP : 80.87.202.40 / Your IP : 216.73.216.169 Web Server : Apache System : Linux rospirotorg.ru 5.14.0-539.el9.x86_64 #1 SMP PREEMPT_DYNAMIC Thu Dec 5 22:26:13 UTC 2024 x86_64 User : bitrix ( 600) PHP Version : 8.2.27 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /lib64/python3.9/site-packages/mercurial/revlogutils/__pycache__/ |
Upload File : |
a �+�b� � @ s� d Z ddlmZ ddlZddlZddlmZmZ ddl m Z mZ ddlm Z dZdZd Zd ZdZdZd ZdZdZdZdZdZe�d�Ze�d�Zdd� Zdd� Zd dd�Zdd� Z dd� Z!dS )!aa core code for "sidedata" support The "sidedata" are stored alongside the revision without actually being part of its content and not affecting its hash. It's main use cases is to cache important information related to a changesets. The current implementation is experimental and subject to changes. Do not rely on it in production. Sidedata are stored in the revlog itself, thanks to a new version of the revlog. The following format is currently used:: initial header: <number of sidedata; 2 bytes> sidedata (repeated N times): <sidedata-key; 2 bytes> <sidedata-entry-length: 4 bytes> <sidedata-content-sha1-digest: 20 bytes> <sidedata-content; X bytes> normal raw text: <all bytes remaining in the rawtext> This is a simple and effective format. It should be enough to experiment with the concept. � )�absolute_importN� )�error�requirements)� constants�flagutil)�hashutil� � � � � � � � � � � z>Hz>HL20sc C s~ t | �� �} | �� t�t| ��g}| D ].\}}t�|��� }|� t �|t|�|�� q(| D ]\}}|� |� q\d�|�}|S )N� )�list�items�sort�SIDEDATA_HEADER�pack�lenr �sha1�digest�append�SIDEDATA_ENTRY�join)�sidedata�buf�key�valuer � r$ �D/usr/lib64/python3.9/site-packages/mercurial/revlogutils/sidedata.py�serialize_sidedata@ s r&