Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/requirements.py @ 48623:baddab229b86
stream-clone: add a explicit set list requirements relevant to stream clone
This set explicitly lists all the requirements that "stream clone" will
preserve. Any other one will not be preserved.
The role of listing the relevant one was previously filled by
`repo.supportedformat`, but it seems clearer to use that such global and
explicit set. The `repo.supportedformat` attribute will be cleaned up in a later
changeset
The true meaning of `repo.supportedformat` vs `repo._basesupported` was lost
over time so, the content is currently bad. For example, `dirstate-v2` is
currently considered relevant to the stream clone, or internal phase is
missing. We kept the same content in this changeset and we will fix them later.
Differential Revision: https://phab.mercurial-scm.org/D12032
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Mon, 17 Jan 2022 19:26:36 +0100 |
parents | dfbfa802876b |
children | 66b59fbb0cdd |
comparison
equal
deleted
inserted
replaced
48622:d9017df70135 | 48623:baddab229b86 |
---|---|
87 SHARED_REQUIREMENT, | 87 SHARED_REQUIREMENT, |
88 RELATIVE_SHARED_REQUIREMENT, | 88 RELATIVE_SHARED_REQUIREMENT, |
89 SHARESAFE_REQUIREMENT, | 89 SHARESAFE_REQUIREMENT, |
90 DIRSTATE_V2_REQUIREMENT, | 90 DIRSTATE_V2_REQUIREMENT, |
91 } | 91 } |
92 | |
93 # List of requirement that impact "stream-clone" (and hardlink clone) and | |
94 # cannot be changed in such cases. | |
95 # | |
96 # requirements not in this list are safe to be altered during stream-clone. | |
97 # | |
98 # note: the list is currently inherited from previous code and miss some relevant requirement while containing some irrelevant ones. | |
99 STREAM_FIXED_REQUIREMENTS = { | |
100 BOOKMARKS_IN_STORE_REQUIREMENT, | |
101 CHANGELOGV2_REQUIREMENT, | |
102 COPIESSDC_REQUIREMENT, | |
103 DIRSTATE_V2_REQUIREMENT, | |
104 GENERALDELTA_REQUIREMENT, | |
105 NODEMAP_REQUIREMENT, | |
106 REVLOGV1_REQUIREMENT, | |
107 REVLOGV2_REQUIREMENT, | |
108 SHARESAFE_REQUIREMENT, | |
109 SPARSEREVLOG_REQUIREMENT, | |
110 TREEMANIFEST_REQUIREMENT, | |
111 } |