comparison mercurial/requirements.py @ 48652:6fd9a17c32ab

requirements: add an official `REVLOG_COMPRESSION_ZSTD` const Such constant was missing and its value was missing from the set of requirements that needs to be preserved through stream clone. This did not had any consequence yet as the "bundle 2 does not filter its requirements" is shadowing the issue. However we are now in a situation where we can fix this issue. So lets do it next. With the preparation work on test, changing the streamreqs value only impact two tests, where checking the full value seems to remains relevant. Important note: Since older version of Mercurial used the old `supportedformat` class attribute to check for stream requirement they supported, older version will consider this requirements to prevent them from using streaming clone. Even as they support this requirements for years. Pack for stable will be send to fix it, but they will have to be backported to older version if needed. Differential Revision: https://phab.mercurial-scm.org/D12083
author Pierre-Yves David <pierre-yves.david@octobus.net>
date Mon, 24 Jan 2022 12:44:20 +0100
parents 66b59fbb0cdd
children eb5c33f1d08f
comparison
equal deleted inserted replaced
48651:c3239f2ee61b 48652:6fd9a17c32ab
33 33
34 # Stores manifest in Tree structure 34 # Stores manifest in Tree structure
35 TREEMANIFEST_REQUIREMENT = b'treemanifest' 35 TREEMANIFEST_REQUIREMENT = b'treemanifest'
36 36
37 REVLOGV1_REQUIREMENT = b'revlogv1' 37 REVLOGV1_REQUIREMENT = b'revlogv1'
38
39 # allow using ZSTD as compression engine for revlog content
40 REVLOG_COMPRESSION_ZSTD = b'revlog-compression-zstd'
38 41
39 # Increment the sub-version when the revlog v2 format changes to lock out old 42 # Increment the sub-version when the revlog v2 format changes to lock out old
40 # clients. 43 # clients.
41 CHANGELOGV2_REQUIREMENT = b'exp-changelog-v2' 44 CHANGELOGV2_REQUIREMENT = b'exp-changelog-v2'
42 45
107 CHANGELOGV2_REQUIREMENT, 110 CHANGELOGV2_REQUIREMENT,
108 COPIESSDC_REQUIREMENT, 111 COPIESSDC_REQUIREMENT,
109 DIRSTATE_V2_REQUIREMENT, 112 DIRSTATE_V2_REQUIREMENT,
110 GENERALDELTA_REQUIREMENT, 113 GENERALDELTA_REQUIREMENT,
111 NODEMAP_REQUIREMENT, 114 NODEMAP_REQUIREMENT,
115 REVLOG_COMPRESSION_ZSTD,
112 REVLOGV1_REQUIREMENT, 116 REVLOGV1_REQUIREMENT,
113 REVLOGV2_REQUIREMENT, 117 REVLOGV2_REQUIREMENT,
114 SHARESAFE_REQUIREMENT, 118 SHARESAFE_REQUIREMENT,
115 SPARSEREVLOG_REQUIREMENT, 119 SPARSEREVLOG_REQUIREMENT,
116 TREEMANIFEST_REQUIREMENT, 120 TREEMANIFEST_REQUIREMENT,