hgitaly 2.9.0__tar.gz → 2.11.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (298) hide show
  1. {hgitaly-2.9.0 → hgitaly-2.11.0}/PKG-INFO +2 -2
  2. hgitaly-2.11.0/hgitaly/VERSION +1 -0
  3. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/gitlab_ref.py +51 -3
  4. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/mercurial_repository.py +60 -1
  5. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/fixture.py +7 -12
  6. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_mercurial_operations.py +9 -45
  7. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_mercurial_repository.py +20 -0
  8. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_operations.py +3 -17
  9. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_ref.py +15 -19
  10. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/ssh.py +2 -0
  11. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_repository_pb2.py +13 -5
  12. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_repository_pb2_grpc.py +34 -0
  13. hgitaly-2.11.0/hgitaly/stub/remote_pb2.py +55 -0
  14. hgitaly-2.11.0/hgitaly/stub/remote_pb2_grpc.py +151 -0
  15. hgitaly-2.11.0/hgitaly/testing/storage.py +27 -0
  16. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/common.py +5 -7
  17. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_gitlab_ref.py +21 -0
  18. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_workdir.py +98 -1
  19. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/workdir.py +104 -16
  20. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/PKG-INFO +2 -2
  21. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/SOURCES.txt +4 -129
  22. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/requires.txt +1 -1
  23. {hgitaly-2.9.0 → hgitaly-2.11.0}/install-requirements.txt +1 -1
  24. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/comparison.py +29 -4
  25. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/conftest.py +17 -0
  26. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/gitaly.py +8 -4
  27. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/hgitaly_rhgitaly_comparison.py +5 -5
  28. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/rhgitaly.py +2 -1
  29. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_gitaly_server.py +7 -4
  30. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_mercurial_repository.py +80 -0
  31. hgitaly-2.11.0/tests_with_gitaly/test_remote.py +125 -0
  32. hgitaly-2.9.0/.coveragerc +0 -5
  33. hgitaly-2.9.0/.gitlab-ci.yml +0 -150
  34. hgitaly-2.9.0/.hgignore +0 -34
  35. hgitaly-2.9.0/.hgtags +0 -128
  36. hgitaly-2.9.0/ci/heptapod-sftp-push +0 -31
  37. hgitaly-2.9.0/ci/heptapod-sign-package +0 -34
  38. hgitaly-2.9.0/ci/heptapod_known_hosts.ssh +0 -4
  39. hgitaly-2.9.0/ci/upload-rhgitaly +0 -43
  40. hgitaly-2.9.0/conftest.py +0 -88
  41. hgitaly-2.9.0/dev-requirements.txt +0 -2
  42. hgitaly-2.9.0/examples/client.py +0 -48
  43. hgitaly-2.9.0/examples/client_list_lcft.py +0 -55
  44. hgitaly-2.9.0/generate-stubs +0 -33
  45. hgitaly-2.9.0/hgitaly/VERSION +0 -1
  46. hgitaly-2.9.0/hgitaly/license_detector/GPL-2.sample +0 -339
  47. hgitaly-2.9.0/hgitaly/testing/data/authorized_keys +0 -1
  48. hgitaly-2.9.0/hgitaly/testing/data/backup_additional_no_git.tar +0 -0
  49. hgitaly-2.9.0/hgitaly/testing/data/id_ecdsa_user +0 -38
  50. hgitaly-2.9.0/hgitaly/testing/data/known_hosts +0 -1
  51. hgitaly-2.9.0/hgitaly/testing/data/ssh_host_ecdsa_key +0 -9
  52. hgitaly-2.9.0/hgitaly/testing/data/ssh_host_ecdsa_key.pub +0 -1
  53. hgitaly-2.9.0/hgitaly/testing/data/sshd_config +0 -17
  54. hgitaly-2.9.0/lint +0 -3
  55. hgitaly-2.9.0/protos/analysis.proto +0 -62
  56. hgitaly-2.9.0/protos/blob.proto +0 -299
  57. hgitaly-2.9.0/protos/cleanup.proto +0 -88
  58. hgitaly-2.9.0/protos/cluster.proto +0 -107
  59. hgitaly-2.9.0/protos/commit.proto +0 -985
  60. hgitaly-2.9.0/protos/conflicts.proto +0 -137
  61. hgitaly-2.9.0/protos/diff.proto +0 -616
  62. hgitaly-2.9.0/protos/errors.proto +0 -228
  63. hgitaly-2.9.0/protos/hook.proto +0 -205
  64. hgitaly-2.9.0/protos/internal.proto +0 -37
  65. hgitaly-2.9.0/protos/lint.proto +0 -75
  66. hgitaly-2.9.0/protos/log.proto +0 -147
  67. hgitaly-2.9.0/protos/mercurial-changeset.proto +0 -96
  68. hgitaly-2.9.0/protos/mercurial-operations.proto +0 -163
  69. hgitaly-2.9.0/protos/mercurial-repository.proto +0 -304
  70. hgitaly-2.9.0/protos/namespace.proto +0 -98
  71. hgitaly-2.9.0/protos/objectpool.proto +0 -173
  72. hgitaly-2.9.0/protos/operations.proto +0 -1139
  73. hgitaly-2.9.0/protos/packfile.proto +0 -26
  74. hgitaly-2.9.0/protos/partition.proto +0 -70
  75. hgitaly-2.9.0/protos/praefect.proto +0 -222
  76. hgitaly-2.9.0/protos/ref.proto +0 -593
  77. hgitaly-2.9.0/protos/remote.proto +0 -153
  78. hgitaly-2.9.0/protos/repository.proto +0 -1342
  79. hgitaly-2.9.0/protos/server.proto +0 -123
  80. hgitaly-2.9.0/protos/service_config.proto +0 -86
  81. hgitaly-2.9.0/protos/shared.proto +0 -248
  82. hgitaly-2.9.0/protos/smarthttp.proto +0 -121
  83. hgitaly-2.9.0/protos/ssh.proto +0 -150
  84. hgitaly-2.9.0/protos/transaction.proto +0 -104
  85. hgitaly-2.9.0/protos/wiki.proto +0 -211
  86. hgitaly-2.9.0/ruby/.ruby-version +0 -1
  87. hgitaly-2.9.0/ruby/Gemfile +0 -5
  88. hgitaly-2.9.0/ruby/README.md +0 -48
  89. hgitaly-2.9.0/ruby/generate-grpc-lib +0 -63
  90. hgitaly-2.9.0/ruby/hgitaly.gemspec +0 -25
  91. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-changeset_pb.rb +0 -69
  92. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-changeset_services_pb.rb +0 -25
  93. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-operations_pb.rb +0 -103
  94. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-operations_services_pb.rb +0 -39
  95. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-repository_pb.rb +0 -141
  96. hgitaly-2.9.0/ruby/lib/hgitaly/mercurial-repository_services_pb.rb +0 -77
  97. hgitaly-2.9.0/ruby/lib/hgitaly/version.rb +0 -4
  98. hgitaly-2.9.0/ruby/lib/hgitaly.rb +0 -11
  99. hgitaly-2.9.0/ruby/run.rb +0 -39
  100. hgitaly-2.9.0/run-all-tests +0 -19
  101. hgitaly-2.9.0/rust/Cargo.lock +0 -2421
  102. hgitaly-2.9.0/rust/Cargo.toml +0 -3
  103. hgitaly-2.9.0/rust/Makefile +0 -69
  104. hgitaly-2.9.0/rust/build-from-tarball.sh +0 -30
  105. hgitaly-2.9.0/rust/check-line-width +0 -48
  106. hgitaly-2.9.0/rust/dependencies/README.md +0 -19
  107. hgitaly-2.9.0/rust/dependencies/mercurial.patch +0 -48
  108. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/any.proto +0 -158
  109. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/api.proto +0 -208
  110. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/compiler/plugin.proto +0 -183
  111. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/descriptor.proto +0 -911
  112. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/duration.proto +0 -116
  113. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/empty.proto +0 -52
  114. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/field_mask.proto +0 -245
  115. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/source_context.proto +0 -48
  116. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/struct.proto +0 -95
  117. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/timestamp.proto +0 -147
  118. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/type.proto +0 -187
  119. hgitaly-2.9.0/rust/dependencies/proto/google/protobuf/wrappers.proto +0 -123
  120. hgitaly-2.9.0/rust/go-enry.rev +0 -1
  121. hgitaly-2.9.0/rust/lint +0 -14
  122. hgitaly-2.9.0/rust/mercurial.rev +0 -1
  123. hgitaly-2.9.0/rust/rhgitaly/Cargo.toml +0 -40
  124. hgitaly-2.9.0/rust/rhgitaly/build.rs +0 -43
  125. hgitaly-2.9.0/rust/rhgitaly/clippy.toml +0 -6
  126. hgitaly-2.9.0/rust/rhgitaly/src/config.rs +0 -130
  127. hgitaly-2.9.0/rust/rhgitaly/src/errors.rs +0 -123
  128. hgitaly-2.9.0/rust/rhgitaly/src/generated/README.md +0 -7
  129. hgitaly-2.9.0/rust/rhgitaly/src/git.rs +0 -293
  130. hgitaly-2.9.0/rust/rhgitaly/src/gitlab/mod.rs +0 -42
  131. hgitaly-2.9.0/rust/rhgitaly/src/gitlab/reference.rs +0 -83
  132. hgitaly-2.9.0/rust/rhgitaly/src/gitlab/revision.rs +0 -320
  133. hgitaly-2.9.0/rust/rhgitaly/src/gitlab/state.rs +0 -508
  134. hgitaly-2.9.0/rust/rhgitaly/src/glob.rs +0 -45
  135. hgitaly-2.9.0/rust/rhgitaly/src/lib.rs +0 -40
  136. hgitaly-2.9.0/rust/rhgitaly/src/main.rs +0 -113
  137. hgitaly-2.9.0/rust/rhgitaly/src/mercurial.rs +0 -1362
  138. hgitaly-2.9.0/rust/rhgitaly/src/message.rs +0 -469
  139. hgitaly-2.9.0/rust/rhgitaly/src/metadata.rs +0 -27
  140. hgitaly-2.9.0/rust/rhgitaly/src/oid.rs +0 -87
  141. hgitaly-2.9.0/rust/rhgitaly/src/process.rs +0 -39
  142. hgitaly-2.9.0/rust/rhgitaly/src/repository.rs +0 -814
  143. hgitaly-2.9.0/rust/rhgitaly/src/service/analysis.rs +0 -184
  144. hgitaly-2.9.0/rust/rhgitaly/src/service/blob.rs +0 -256
  145. hgitaly-2.9.0/rust/rhgitaly/src/service/commit/find_commits.rs +0 -202
  146. hgitaly-2.9.0/rust/rhgitaly/src/service/commit/get_tree_entries.rs +0 -291
  147. hgitaly-2.9.0/rust/rhgitaly/src/service/commit/last_commits.rs +0 -567
  148. hgitaly-2.9.0/rust/rhgitaly/src/service/commit/mod.rs +0 -492
  149. hgitaly-2.9.0/rust/rhgitaly/src/service/commit/tree_entry.rs +0 -155
  150. hgitaly-2.9.0/rust/rhgitaly/src/service/diff.rs +0 -92
  151. hgitaly-2.9.0/rust/rhgitaly/src/service/mercurial_repository.rs +0 -283
  152. hgitaly-2.9.0/rust/rhgitaly/src/service/mod.rs +0 -13
  153. hgitaly-2.9.0/rust/rhgitaly/src/service/ref.rs +0 -634
  154. hgitaly-2.9.0/rust/rhgitaly/src/service/repository.rs +0 -275
  155. hgitaly-2.9.0/rust/rhgitaly/src/service/server.rs +0 -34
  156. hgitaly-2.9.0/rust/rhgitaly/src/sidecar.rs +0 -184
  157. hgitaly-2.9.0/rust/rhgitaly/src/streaming.rs +0 -339
  158. hgitaly-2.9.0/rust/rhgitaly/src/util.rs +0 -132
  159. hgitaly-2.9.0/rust/rs-enry.rev +0 -1
  160. hgitaly-2.9.0/rust/src-tarball.sh +0 -60
  161. hgitaly-2.9.0/test-requirements.txt +0 -7
  162. {hgitaly-2.9.0 → hgitaly-2.11.0}/LICENSE +0 -0
  163. {hgitaly-2.9.0 → hgitaly-2.11.0}/MANIFEST.in +0 -0
  164. {hgitaly-2.9.0 → hgitaly-2.11.0}/README.md +0 -0
  165. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/__init__.py +0 -0
  166. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/hgitaly/__init__.py +0 -0
  167. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/hgitaly/revset.py +0 -0
  168. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/hgitaly/tests/__init__.py +0 -0
  169. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/hgitaly/tests/test_revset.py +0 -0
  170. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgext3rd/hgitaly/tests/test_serve.py +0 -0
  171. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/__init__.py +0 -0
  172. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/branch.py +0 -0
  173. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/changelog.py +0 -0
  174. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/diff.py +0 -0
  175. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/errors.py +0 -0
  176. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/feature.py +0 -0
  177. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/file_content.py +0 -0
  178. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/file_context.py +0 -0
  179. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/git.py +0 -0
  180. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/license_detector/__init__.py +0 -0
  181. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/license_detector/spdx-licenses.json +0 -0
  182. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/linguist/__init__.py +0 -0
  183. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/linguist/languages.json +0 -0
  184. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/logging.py +0 -0
  185. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/manifest.py +0 -0
  186. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/message.py +0 -0
  187. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/oid.py +0 -0
  188. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/pagination.py +0 -0
  189. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/path.py +0 -0
  190. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/peer.py +0 -0
  191. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/procutil.py +0 -0
  192. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/repository.py +0 -0
  193. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/revision.py +0 -0
  194. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/revset.py +0 -0
  195. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/scripts.py +0 -0
  196. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/__init__.py +0 -0
  197. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/address.py +0 -0
  198. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/mono.py +0 -0
  199. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/prefork.py +0 -0
  200. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/tests/__init__.py +0 -0
  201. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/tests/test_address.py +0 -0
  202. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/tests/test_mono.py +0 -0
  203. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/tests/test_prefork.py +0 -0
  204. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/tests/test_worker.py +0 -0
  205. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/server/worker.py +0 -0
  206. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/__init__.py +0 -0
  207. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/analysis.py +0 -0
  208. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/blob.py +0 -0
  209. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/commit.py +0 -0
  210. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/diff.py +0 -0
  211. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/interceptors.py +0 -0
  212. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/mercurial_changeset.py +0 -0
  213. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/mercurial_operations.py +0 -0
  214. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/operations.py +0 -0
  215. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/ref.py +0 -0
  216. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/repository.py +0 -0
  217. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/server.py +0 -0
  218. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/__init__.py +0 -0
  219. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_analysis.py +0 -0
  220. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_blob.py +0 -0
  221. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_commit.py +0 -0
  222. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_default_branch.py +0 -0
  223. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_diff.py +0 -0
  224. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_mercurial_changeset.py +0 -0
  225. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_repository_service.py +0 -0
  226. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/service/tests/test_server.py +0 -0
  227. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/servicer.py +0 -0
  228. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stream.py +0 -0
  229. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/__init__.py +0 -0
  230. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/analysis_pb2.py +0 -0
  231. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/analysis_pb2_grpc.py +0 -0
  232. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/blob_pb2.py +0 -0
  233. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/blob_pb2_grpc.py +0 -0
  234. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/commit_pb2.py +0 -0
  235. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/commit_pb2_grpc.py +0 -0
  236. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/diff_pb2.py +0 -0
  237. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/diff_pb2_grpc.py +0 -0
  238. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/errors_pb2.py +0 -0
  239. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/errors_pb2_grpc.py +0 -0
  240. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/lint_pb2.py +0 -0
  241. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/lint_pb2_grpc.py +0 -0
  242. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_changeset_pb2.py +0 -0
  243. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_changeset_pb2_grpc.py +0 -0
  244. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_operations_pb2.py +0 -0
  245. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/mercurial_operations_pb2_grpc.py +0 -0
  246. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/operations_pb2.py +0 -0
  247. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/operations_pb2_grpc.py +0 -0
  248. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/ref_pb2.py +0 -0
  249. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/ref_pb2_grpc.py +0 -0
  250. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/repository_pb2.py +0 -0
  251. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/repository_pb2_grpc.py +0 -0
  252. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/server_pb2.py +0 -0
  253. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/server_pb2_grpc.py +0 -0
  254. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/shared_pb2.py +0 -0
  255. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/stub/shared_pb2_grpc.py +0 -0
  256. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tag.py +0 -0
  257. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/__init__.py +0 -0
  258. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/bundle.py +0 -0
  259. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/context.py +0 -0
  260. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/grpc.py +0 -0
  261. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/ssh.py +0 -0
  262. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/sshd.py +0 -0
  263. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/tests/__init__.py +0 -0
  264. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/testing/tests/test_sshd.py +0 -0
  265. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/__init__.py +0 -0
  266. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_branch.py +0 -0
  267. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_diff.py +0 -0
  268. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_errors.py +0 -0
  269. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_feature.py +0 -0
  270. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_file_context.py +0 -0
  271. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_license_detector.py +0 -0
  272. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_linguist.py +0 -0
  273. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_manifest.py +0 -0
  274. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_messages.py +0 -0
  275. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_oid.py +0 -0
  276. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_peer.py +0 -0
  277. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_repository.py +0 -0
  278. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_revision.py +0 -0
  279. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_revset.py +0 -0
  280. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_servicer.py +0 -0
  281. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_stream.py +0 -0
  282. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/tests/test_tag.py +0 -0
  283. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly/util.py +0 -0
  284. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/dependency_links.txt +0 -0
  285. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/entry_points.txt +0 -0
  286. {hgitaly-2.9.0 → hgitaly-2.11.0}/hgitaly.egg-info/top_level.txt +0 -0
  287. {hgitaly-2.9.0 → hgitaly-2.11.0}/setup.cfg +0 -0
  288. {hgitaly-2.9.0 → hgitaly-2.11.0}/setup.py +0 -0
  289. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/__init__.py +0 -0
  290. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_blob_tree.py +0 -0
  291. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_commit.py +0 -0
  292. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_comparison.py +0 -0
  293. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_diff.py +0 -0
  294. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_operations.py +0 -0
  295. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_ref.py +0 -0
  296. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_repository_service.py +0 -0
  297. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_rhgitaly_server.py +0 -0
  298. {hgitaly-2.9.0 → hgitaly-2.11.0}/tests_with_gitaly/test_server.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: hgitaly
3
- Version: 2.9.0
3
+ Version: 2.11.0
4
4
  Summary: Server-side implementation of Gitaly protocol for Mercurial
5
5
  Home-page: https://foss.heptapod.net/heptapod/hgitaly
6
6
  Author: Georges Racinet
@@ -10,7 +10,7 @@ Keywords: hg mercurial heptapod gitlab
10
10
  Requires-Python: >=3.8
11
11
  Description-Content-Type: text/markdown
12
12
  License-File: LICENSE
13
- Requires-Dist: heptapod>=4.8.0dev0
13
+ Requires-Dist: heptapod>=5.0.0dev0
14
14
  Requires-Dist: protobuf~=4.21.0
15
15
  Requires-Dist: grpcio~=1.58.0
16
16
  Requires-Dist: grpcio-status~=1.58.0
@@ -0,0 +1 @@
1
+ 2.11.0
@@ -13,6 +13,8 @@ utilities about refs, i.e, anything about a full ref path, such as
13
13
  or tags.
14
14
  """
15
15
  from fnmatch import fnmatch
16
+ import os
17
+ import re
16
18
 
17
19
  from heptapod.gitlab.branch import gitlab_branch_ref
18
20
  from heptapod.gitlab.tag import gitlab_tag_ref
@@ -30,10 +32,40 @@ from hgext3rd.heptapod.special_ref import (
30
32
  )
31
33
  from hgext3rd.heptapod.keep_around import (
32
34
  iter_keep_arounds,
35
+ init_keep_arounds,
33
36
  KEEP_AROUND_REF_PREFIX,
34
37
  KEEP_AROUND_REF_PREFIX_LEN,
35
38
  )
36
39
 
40
+ DOT_HG_RX = re.compile(br'\.hg$')
41
+
42
+
43
+ def has_legacy_git_repo(repo):
44
+ """Return whether there is a legacy Git repo for this Mercurial repo.
45
+
46
+ With "legacy" here is meant the Git repository for a non-native project.
47
+ Git repositories meant for mirroring are *not* included in this scope.
48
+
49
+ As of Heptapod 17.6, this is the best way to know without direct indication
50
+ (from the inside) that a repository is not legacy (hg-git based).
51
+ The reverse implication is false, as there are loopholes:
52
+
53
+ - leftover Git repositories for Projects that have migrated to native
54
+ - native projects with addition conversion for mirrors whose Git
55
+ repositories have not been moved yet (bug, time to run the migration,
56
+ etc.)
57
+
58
+ The caller must be aware of these loopholes and avoid overwriting existing
59
+ data based on the legacy Git repo. In the intended case where this is to
60
+ decide on calling the `ensure` methods, this means it is ok only if there
61
+ is no existing data.
62
+ """
63
+ # if a repository is legacy, based on hg-git conversion, is whether
64
+ # it has a `.git` repository at the same location. Git repositories
65
+ # for mirroring are in a different place
66
+ git_path = DOT_HG_RX.sub(b'', repo.root) + b'.git'
67
+ return os.path.exists(git_path)
68
+
37
69
 
38
70
  def gitlab_special_ref_target(repo, ref_path):
39
71
  """Return the changeset for a special ref.
@@ -115,7 +147,23 @@ def iter_gitlab_special_refs_as_refs(repo, deref=True, patterns=None):
115
147
 
116
148
 
117
149
  def ensure_special_refs(repo):
118
- return ensure_gitlab_special_refs(repo.ui, repo)
150
+ if has_legacy_git_repo(repo):
151
+ return ensure_gitlab_special_refs(repo.ui, repo)
152
+ return {}
153
+
154
+
155
+ def ensure_keep_arounds(repo, init_empty=False):
156
+ """Ensure keep around from Git repo if present or create.
157
+
158
+ An empty file is created so that the keep-arounds file is no
159
+ more missing, but only if `init_empty` is `True`, so that
160
+ responsibility is handed to the caller, than must use the
161
+ option only after having obtained the missing marker.
162
+ """
163
+ if has_legacy_git_repo(repo):
164
+ ensure_gitlab_keep_arounds(repo.ui, repo)
165
+ elif init_empty:
166
+ init_keep_arounds(repo, ())
119
167
 
120
168
 
121
169
  def has_keep_around(repo, sha):
@@ -125,7 +173,7 @@ def has_keep_around(repo, sha):
125
173
  """
126
174
  for ka in iter_keep_arounds(repo):
127
175
  if ka is GITLAB_TYPED_REFS_MISSING:
128
- ensure_gitlab_keep_arounds(repo.ui, repo)
176
+ ensure_keep_arounds(repo, init_empty=True)
129
177
  return has_keep_around(repo, sha)
130
178
  if ka == sha:
131
179
  return True
@@ -146,7 +194,7 @@ def parse_keep_around_ref_path(ref):
146
194
  def iter_keep_arounds_as_refs(repo, deref=True, patterns=None):
147
195
  for sha in iter_keep_arounds(repo):
148
196
  if sha is GITLAB_TYPED_REFS_MISSING:
149
- ensure_gitlab_keep_arounds(repo.ui, repo)
197
+ ensure_keep_arounds(repo, init_empty=True)
150
198
  yield from iter_keep_arounds_as_refs(repo, deref=deref)
151
199
  return
152
200
  ref_path = keep_around_ref_path(sha)
@@ -16,6 +16,7 @@ from mercurial import (
16
16
  )
17
17
 
18
18
  from ..branch import iter_gitlab_branches_matching
19
+ from ..logging import LoggerAdapter
19
20
  from ..peer import (
20
21
  FileURLOutsidePath,
21
22
  InvalidURLScheme,
@@ -30,6 +31,10 @@ from ..repository import (
30
31
  set_config_inheritance,
31
32
  set_managed_config,
32
33
  )
34
+ from ..workdir import (
35
+ remove_unlisted_workdirs,
36
+ workdirs_gc,
37
+ )
33
38
  from ..errors import (
34
39
  not_implemented,
35
40
  )
@@ -39,6 +44,8 @@ from ..stub.mercurial_repository_pb2 import (
39
44
  GetConfigItemResponse,
40
45
  GetManagedConfigRequest,
41
46
  GetManagedConfigResponse,
47
+ HousekeepingRequest,
48
+ HousekeepingResponse,
42
49
  PushRequest,
43
50
  PushResponse,
44
51
  SetManagedConfigRequest,
@@ -49,7 +56,7 @@ from ..stub.mercurial_repository_pb2_grpc import (
49
56
  )
50
57
  from ..servicer import HGitalyServicer
51
58
 
52
- logger = logging.getLogger(__name__)
59
+ base_logger = logging.getLogger(__name__)
53
60
 
54
61
 
55
62
  class MercurialRepositoryServicer(MercurialRepositoryServiceServicer,
@@ -186,3 +193,55 @@ class MercurialRepositoryServicer(MercurialRepositoryServiceServicer,
186
193
  context.abort(StatusCode.INTERNAL,
187
194
  "Unexpected error, not in the actual "
188
195
  "push to %r: %s" % (remote_url, exc))
196
+
197
+ def Housekeeping(self,
198
+ request: HousekeepingRequest,
199
+ context) -> HousekeepingResponse:
200
+ logger = LoggerAdapter(base_logger, context)
201
+ gl_repo = request.repository
202
+ repo = self.load_repo(gl_repo, context)
203
+ tasks = []
204
+ resp_attrs = {}
205
+ if request.fail:
206
+ tasks.append('fail')
207
+ if request.working_directories_age_threshold_seconds:
208
+ tasks.append('working_dirs_gc')
209
+ if request.working_directories_remove_unlisted:
210
+ tasks.append('remove_unlisted_working_dirs')
211
+ if request.recover:
212
+ tasks.append('recover')
213
+ for task in tasks:
214
+ try:
215
+ resp_attrs.update(getattr(self, 'housekeeping_' + task)(
216
+ repo=repo,
217
+ request=request,
218
+ context=context
219
+ ))
220
+ except Exception as exc:
221
+ logger.error("Housekeeping task %s failed: %r" % (task, exc))
222
+
223
+ return HousekeepingResponse(**resp_attrs)
224
+
225
+ def housekeeping_fail(self, *a, **kw):
226
+ raise RuntimeError("client-required failure")
227
+
228
+ def housekeeping_working_dirs_gc(self, repo, request, context):
229
+ workdirs_gc(
230
+ workdirs_root=self.repo_workdirs_root(request.repository, context),
231
+ repo=repo,
232
+ max_age_seconds=request.working_directories_age_threshold_seconds
233
+ )
234
+ return [('working_directories_gc', True)]
235
+
236
+ def housekeeping_remove_unlisted_working_dirs(self, repo,
237
+ request, context):
238
+ remove_unlisted_workdirs(
239
+ repo=repo,
240
+ workdirs_root=self.repo_workdirs_root(request.repository, context),
241
+ )
242
+ return [('working_directories_remove_unlisted', True)]
243
+
244
+ def housekeeping_recover(self, repo, request, context):
245
+ return (('recover_run', True),
246
+ ('recovered_interrupted_transaction', repo.recover()),
247
+ )
@@ -11,7 +11,6 @@ import shutil
11
11
  from hgitaly import feature
12
12
  from hgitaly.logging import CORRELATION_ID_MD_KEY
13
13
  from hgitaly.servicer import (
14
- HG_GIT_MIRRORING_MD_KEY,
15
14
  NATIVE_PROJECT_MD_KEY,
16
15
  PY_HEPTAPOD_SKIP_HOOKS,
17
16
  SKIP_HOOKS_MD_KEY,
@@ -36,6 +35,9 @@ from hgitaly.stub.ref_pb2 import (
36
35
  from hgitaly.stub.shared_pb2 import (
37
36
  User,
38
37
  )
38
+ from hgitaly.testing.storage import (
39
+ stowed_away_git_repo_path,
40
+ )
39
41
 
40
42
  # for coverage of hgitaly.logging
41
43
  intercept_logger.setLevel(logging.DEBUG)
@@ -156,15 +158,11 @@ class ServiceFixture:
156
158
  return self.storage_path(**kw) / rel_path
157
159
 
158
160
  def side_git_repo_path(self, hg_path, **kw):
159
- hg_rel_path = hg_path.relative_to(self.storage_path(**kw))
160
- git_rel_path = str(hg_rel_path).split('.hg', 1)[0] + '.git'
161
- return self.storage_path(**kw) / '+hgitaly/hg-git' / git_rel_path
161
+ return stowed_away_git_repo_path(self.server_repos_root, hg_path,
162
+ **kw)
162
163
 
163
- def side_git_repo(self, hg_path, **kw):
164
- path = self.side_git_repo_path(hg_path, **kw)
165
- if not path.exists(): # can happen if no transaction occurred
166
- path = hg_path.with_suffix('.git')
167
- return GitRepo(path)
164
+ def side_git_repo(self, *a, **kw):
165
+ return GitRepo(self.side_git_repo_path(*a, **kw))
168
166
 
169
167
  def make_repo_wrapper(self, rel_path, **kw):
170
168
  """Utility method to avoid depending too much on actual disk layout.
@@ -216,9 +214,6 @@ class MutationServiceFixture(ServiceFixture):
216
214
  mds = super(MutationServiceFixture, self).grpc_metadata()
217
215
  native = getattr(self, 'hg_native', True)
218
216
  mds.append((NATIVE_PROJECT_MD_KEY, str(native)))
219
- with_mirroring = getattr(self, 'with_hg_git_mirroring', None)
220
- if native and with_mirroring is not None:
221
- mds.append((HG_GIT_MIRRORING_MD_KEY, str(with_mirroring)))
222
217
  mds.append((SKIP_HOOKS_MD_KEY, 'true'))
223
218
  return mds
224
219
 
@@ -219,17 +219,10 @@ def test_merge_analysis_conflict(operations_fixture):
219
219
  )
220
220
 
221
221
 
222
- @parametrize('project_mode', ('hg-git-project',
223
- 'native-project-without-git',
224
- 'native-project-with-git',
225
- ))
222
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
226
223
  def test_publish_changeset(operations_fixture, project_mode):
227
224
  fixture = operations_fixture
228
225
  fixture.hg_native = project_mode != 'hg-git-project'
229
- if fixture.hg_native:
230
- fixture.with_hg_git_mirroring = (
231
- project_mode == 'native-project-with-git'
232
- )
233
226
 
234
227
  wrapper = fixture.repo_wrapper
235
228
 
@@ -273,7 +266,7 @@ def test_publish_changeset(operations_fixture, project_mode):
273
266
 
274
267
  assert fixture.list_refs() == {default_ref: topical.hex().decode()}
275
268
 
276
- if fixture.hg_native and not fixture.with_hg_git_mirroring:
269
+ if fixture.hg_native:
277
270
  # expect Git branches not to have moved
278
271
  assert git_repo.branches() == initial_git_branches
279
272
  else:
@@ -298,19 +291,12 @@ def test_publish_changeset(operations_fixture, project_mode):
298
291
  fixture.publish(gitlab_revision=hex0, hg_perms=WRITE_PERM)
299
292
 
300
293
 
301
- @parametrize('project_mode', ('hg-git-project',
302
- 'native-project-without-git',
303
- 'native-project-with-git',
304
- ))
294
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
305
295
  def test_merge_branch(operations_fixture, project_mode):
306
296
  fixture = operations_fixture
307
297
  merge = fixture.merge_branch
308
298
 
309
299
  fixture.hg_native = project_mode != 'hg-git-project'
310
- if fixture.hg_native:
311
- fixture.with_hg_git_mirroring = (
312
- project_mode == 'native-project-with-git'
313
- )
314
300
  wrapper = fixture.repo_wrapper
315
301
 
316
302
  gl_branch = b'branch/default'
@@ -421,7 +407,7 @@ def test_merge_branch(operations_fixture, project_mode):
421
407
  assert wrapper.repo[ctx2.rev()].phase() == phases.public
422
408
  assert gitlab_branches(wrapper.repo)[gl_branch] == sha2.encode()
423
409
 
424
- if project_mode != 'native-project-without-git':
410
+ if project_mode != 'native-project':
425
411
  git_repo = fixture.git_repo()
426
412
  assert git_repo.branch_titles()[gl_branch] == b'fast-forward'
427
413
 
@@ -441,7 +427,7 @@ def test_merge_branch(operations_fixture, project_mode):
441
427
  assert merge_changeset.p2().hex() == non_linear.encode()
442
428
  assert merge_changeset.description() == b"Actual merge!"
443
429
 
444
- if project_mode != 'native-project-without-git':
430
+ if project_mode != 'native-project':
445
431
  git_repo = fixture.git_repo()
446
432
  assert git_repo.branch_titles()[gl_branch] == b'Actual merge!'
447
433
 
@@ -461,10 +447,7 @@ def test_merge_branch(operations_fixture, project_mode):
461
447
  assert conflict_error.conflicting_files == [b'foo']
462
448
 
463
449
 
464
- @parametrize('project_mode', ('hg-git-project',
465
- 'native-project-without-git',
466
- 'native-project-with-git',
467
- ))
450
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
468
451
  @parametrize('semi_lin_req', ('semi_linear_req', 'classical_req'))
469
452
  def test_merge_linear_named_branch(operations_fixture,
470
453
  project_mode,
@@ -473,10 +456,6 @@ def test_merge_linear_named_branch(operations_fixture,
473
456
  merge = fixture.merge_branch
474
457
 
475
458
  fixture.hg_native = project_mode != 'hg-git-project'
476
- if fixture.hg_native:
477
- fixture.with_hg_git_mirroring = (
478
- project_mode == 'native-project-with-git'
479
- )
480
459
  wrapper = fixture.repo_wrapper
481
460
 
482
461
  gl_branch = b'branch/default'
@@ -511,19 +490,12 @@ def test_merge_linear_named_branch(operations_fixture,
511
490
  assert merge_changeset.description() == merge_msg
512
491
 
513
492
 
514
- @parametrize('project_mode', ('hg-git-project',
515
- 'native-project-without-git',
516
- 'native-project-with-git',
517
- ))
493
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
518
494
  def test_merge_branch_timestamp(operations_fixture, project_mode):
519
495
  fixture = operations_fixture
520
496
  merge = fixture.merge_branch
521
497
 
522
498
  fixture.hg_native = project_mode != 'hg-git-project'
523
- if fixture.hg_native:
524
- fixture.with_hg_git_mirroring = (
525
- project_mode == 'native-project-with-git'
526
- )
527
499
  wrapper = fixture.repo_wrapper
528
500
 
529
501
  gl_branch = b'branch/default'
@@ -553,7 +525,7 @@ def test_merge_branch_timestamp(operations_fixture, project_mode):
553
525
  assert merge.p1().hex() == ctx1.hex()
554
526
  assert merge.p2() == merged
555
527
 
556
- if project_mode != 'native-project-without-git':
528
+ if project_mode != 'native-project':
557
529
  git_repo = fixture.git_repo()
558
530
  git_branch = git_repo.branches()[gl_branch]
559
531
  assert git_branch['title'] == b'we have a date'
@@ -601,21 +573,13 @@ def test_merge_branch_troubled_changesets(operations_fixture):
601
573
  assert merge_error.pre_check == PreCheckUpdateError.UNSTABLE_CHANGESET
602
574
 
603
575
 
604
- @parametrize('project_mode', ('hg-git-project',
605
- 'native-project-without-git',
606
- 'native-project-with-git',
607
- ))
576
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
608
577
  def test_censor(operations_fixture, project_mode):
609
578
  fixture = operations_fixture
610
579
  # The `censor` extension is part of py-heptapod's `required.hgrc`, hence
611
580
  # always there in Heptapod context
612
581
  fixture.repo_wrapper.write_hgrc(dict(extensions=dict(censor='')))
613
582
  fixture.hg_native = project_mode != 'hg-git-project'
614
- if fixture.hg_native:
615
- fixture.with_hg_git_mirroring = (
616
- project_mode == 'native-project-with-git'
617
- )
618
-
619
583
  wrapper = fixture.repo_wrapper
620
584
 
621
585
  ctx0 = wrapper.commit_file('foo', content='oops, secret')
@@ -26,6 +26,7 @@ from hgitaly.stub.mercurial_repository_pb2 import (
26
26
  ConfigItemType,
27
27
  GetConfigItemRequest,
28
28
  GetManagedConfigRequest,
29
+ HousekeepingRequest,
29
30
  SetManagedConfigRequest,
30
31
  HeptapodConfigSection,
31
32
  MercurialPeer,
@@ -86,6 +87,10 @@ class ConfigFixture(ServiceFixture):
86
87
  def include_managed_hgrc(self):
87
88
  self.append_main_hgrc('', '%include hgrc.managed', '')
88
89
 
90
+ def housekeeping(self, **kw):
91
+ kw.setdefault('repository', self.grpc_repo)
92
+ return self.stub.Housekeeping(HousekeepingRequest(**kw))
93
+
89
94
 
90
95
  @pytest.fixture
91
96
  def config_fixture(grpc_channel, server_repos_root):
@@ -511,3 +516,18 @@ def test_push_invalid_url(push_fixture, url):
511
516
  with pytest.raises(grpc.RpcError) as exc_info:
512
517
  push(remote_url=url)
513
518
  assert exc_info.value.code() == grpc.StatusCode.INVALID_ARGUMENT
519
+
520
+
521
+ def test_housekeeping(config_fixture):
522
+ fixture = config_fixture
523
+
524
+ fixture.housekeeping(fail=True)
525
+
526
+ assert fixture.housekeeping(
527
+ working_directories_age_threshold_seconds=1).working_directories_gc
528
+
529
+ fixture.housekeeping(working_directories_remove_unlisted=True)
530
+
531
+ resp = fixture.housekeeping(recover=True)
532
+ assert resp.recover_run
533
+ assert not resp.recovered_interrupted_transaction
@@ -64,10 +64,7 @@ def operations_fixture(grpc_channel, server_repos_root):
64
64
 
65
65
 
66
66
  @parametrize('timestamp', ('timestamp', 'now'))
67
- @parametrize('project_mode', ('hg-git-project',
68
- 'native-project-without-git',
69
- 'native-project-with-git',
70
- ))
67
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
71
68
  def test_user_squash(operations_fixture, project_mode, timestamp):
72
69
  fixture = operations_fixture
73
70
  wrapper = fixture.repo_wrapper
@@ -87,10 +84,6 @@ def test_user_squash(operations_fixture, project_mode, timestamp):
87
84
  squash = fixture.user_squash
88
85
 
89
86
  fixture.hg_native = project_mode != 'hg-git-project'
90
- if fixture.hg_native:
91
- fixture.with_hg_git_mirroring = (
92
- project_mode == 'native-project-with-git'
93
- )
94
87
 
95
88
  if timestamp == 'now':
96
89
  ts = None
@@ -125,7 +118,7 @@ def test_user_squash(operations_fixture, project_mode, timestamp):
125
118
  b'refs/heads/branch/default': folded_sha.decode('ascii')
126
119
  }
127
120
 
128
- if fixture.hg_native and not fixture.with_hg_git_mirroring:
121
+ if fixture.hg_native:
129
122
  # expect Git branches not to have moved
130
123
  assert git_repo.branches() == before_squash_git_branches
131
124
  else:
@@ -163,19 +156,12 @@ def test_user_squash(operations_fixture, project_mode, timestamp):
163
156
  assert amended_ctx.description() == amend_msg
164
157
 
165
158
 
166
- @parametrize('project_mode', ('hg-git-project',
167
- 'native-project-without-git',
168
- 'native-project-with-git',
169
- ))
159
+ @parametrize('project_mode', ('hg-git-project', 'native-project'))
170
160
  def test_user_ff_branch(operations_fixture, project_mode):
171
161
  fixture = operations_fixture
172
162
  ff_branch = fixture.user_ff_branch
173
163
 
174
164
  fixture.hg_native = project_mode != 'hg-git-project'
175
- if fixture.hg_native:
176
- fixture.with_hg_git_mirroring = (
177
- project_mode == 'native-project-with-git'
178
- )
179
165
  wrapper = fixture.repo_wrapper
180
166
 
181
167
  gl_topic = b'topic/default/zetop'
@@ -325,6 +325,11 @@ def test_delete_refs(grpc_channel, server_repos_root):
325
325
  refs=refs,
326
326
  except_with_prefix=except_prefixes))
327
327
 
328
+ def assert_special_refs(expected):
329
+ # it is normal for the client-side repo to need invalidation
330
+ wrapper.reload()
331
+ assert special_refs(wrapper.repo) == expected
332
+
328
333
  with pytest.raises(grpc.RpcError) as exc_info:
329
334
  do_rpc(refs=[b'xy'], except_prefixes=[b'refs/heads'])
330
335
  assert exc_info.value.code() == grpc.StatusCode.INVALID_ARGUMENT
@@ -343,26 +348,19 @@ def test_delete_refs(grpc_channel, server_repos_root):
343
348
 
344
349
  write_gitlab_special_ref(repo, special_ref_name, ctx.hex())
345
350
  # double check
346
- assert special_refs(repo) == {special_ref_name: ctx.hex()}
351
+ assert_special_refs({special_ref_name: ctx.hex()})
347
352
 
348
- # go (it is normal for the client-side repo to need invalidation)
353
+ # go
349
354
  assert not do_rpc([special_ref_path]).git_error
350
- # TODO use the future wrapper.reload()
351
- setattr(repo, '_gitlab_refs_special-refs', None)
352
- assert special_refs(repo) == {}
355
+ assert_special_refs({})
353
356
 
354
357
  # case where one mixes unknown and known refs
355
358
  write_gitlab_special_ref(repo, special_ref_name, ctx.hex())
356
- # TODO use the future wrapper.reload()
357
- setattr(repo, '_gitlab_refs_special-refs', None)
358
359
  # double check
359
- assert special_refs(repo) == {special_ref_name: ctx.hex()}
360
+ assert_special_refs({special_ref_name: ctx.hex()})
360
361
  mixed_refs = [special_ref_path, b'refs/merge-requests/12/head']
361
362
  assert not do_rpc(mixed_refs).git_error
362
-
363
- # TODO use the future wrapper.reload()
364
- setattr(repo, '_gitlab_refs_special-refs', None)
365
- assert special_refs(repo) == {}
363
+ assert_special_refs({})
366
364
 
367
365
  other_special_ref_name = b'environments/124'
368
366
  for prefix in (b'refs/environments',
@@ -371,21 +369,19 @@ def test_delete_refs(grpc_channel, server_repos_root):
371
369
  write_gitlab_special_ref(repo, special_ref_name, ctx.hex())
372
370
  write_gitlab_special_ref(repo, other_special_ref_name, ctx.hex())
373
371
  # double check
374
- assert special_refs(repo) == {special_ref_name: ctx.hex(),
375
- other_special_ref_name: ctx.hex()}
372
+ assert_special_refs({special_ref_name: ctx.hex(),
373
+ other_special_ref_name: ctx.hex()})
376
374
 
377
375
  assert not do_rpc(except_prefixes=[prefix]).git_error
378
- # TODO use the future wrapper.reload()
379
- setattr(repo, '_gitlab_refs_special-refs', None)
380
- assert special_refs(repo) == {other_special_ref_name: ctx.hex()}
376
+ assert_special_refs({other_special_ref_name: ctx.hex()})
381
377
 
382
378
  # exclusion matching both special refs
383
379
  write_gitlab_special_ref(repo, special_ref_name, ctx.hex())
384
380
  write_gitlab_special_ref(repo, other_special_ref_name, ctx.hex())
385
381
  assert not do_rpc(except_prefixes=[b'refs/environ',
386
382
  b'refs/pipel']).git_error
387
- assert special_refs(repo) == {special_ref_name: ctx.hex(),
388
- other_special_ref_name: ctx.hex()}
383
+ assert_special_refs({special_ref_name: ctx.hex(),
384
+ other_special_ref_name: ctx.hex()})
389
385
 
390
386
 
391
387
  def test_list_branch_names_containing_commit(grpc_channel, server_repos_root):
@@ -17,6 +17,8 @@ def client_command(priv_key, known_hosts):
17
17
 
18
18
  :param str priv_key: non-encrypted private key file content.
19
19
  """
20
+ # delete_on_close appears with Python 3.12, and it allows *not* to
21
+ # remove when exiting the context.
20
22
  with (
21
23
  NamedTemporaryFile(mode='w', delete=False) as keyf,
22
24
  NamedTemporaryFile(mode='w', delete=False) as known_hostsf,
@@ -15,7 +15,7 @@ from . import lint_pb2 as lint__pb2
15
15
  from . import shared_pb2 as shared__pb2
16
16
 
17
17
 
18
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1amercurial-repository.proto\x12\x07hgitaly\x1a\nlint.proto\x1a\x0cshared.proto\"Y\n\x11InitConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x16\n\x0enamespace_path\x18\x02 \x01(\t\"\x14\n\x12InitConfigResponse\"\x95\x02\n\x15HeptapodConfigSection\x12!\n\x14\x61llow_multiple_heads\x18\x02 \x01(\x08H\x00\x88\x01\x01\x12\x1c\n\x0f\x61llow_bookmarks\x18\x03 \x01(\x08H\x01\x88\x01\x01\x12\x45\n\x0c\x61uto_publish\x18\x04 \x01(\x0e\x32*.hgitaly.HeptapodConfigSection.AutoPublishH\x02\x88\x01\x01\"6\n\x0b\x41utoPublish\x12\x11\n\rWITHOUT_TOPIC\x10\x00\x12\x0b\n\x07NOTHING\x10\x01\x12\x07\n\x03\x41LL\x10\x02\x42\x17\n\x15_allow_multiple_headsB\x12\n\x10_allow_bookmarksB\x0f\n\r_auto_publish\"V\n\x17GetManagedConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\r\n\x05local\x18\x02 \x01(\x08\"]\n\x18GetManagedConfigResponse\x12\x0f\n\x07inherit\x18\x01 \x01(\x08\x12\x30\n\x08heptapod\x18\x02 \x01(\x0b\x32\x1e.hgitaly.HeptapodConfigSection\"\xc2\x01\n\x17SetManagedConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x14\n\x07inherit\x18\x02 \x01(\x08H\x00\x88\x01\x01\x12\x30\n\x08heptapod\x18\x03 \x01(\x0b\x32\x1e.hgitaly.HeptapodConfigSection\x12\x14\n\x0cremove_items\x18\x04 \x03(\t\x12\x0f\n\x07\x62y_line\x18\x05 \x01(\tB\n\n\x08_inherit\"\x1a\n\x18SetManagedConfigResponse\"\x8d\x01\n\x14GetConfigItemRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12(\n\x07\x61s_type\x18\x02 \x01(\x0e\x32\x17.hgitaly.ConfigItemType\x12\x0f\n\x07section\x18\x03 \x01(\t\x12\x0c\n\x04name\x18\x04 \x01(\t\"H\n\x15GetConfigItemResponse\x12\x13\n\tas_string\x18\x01 \x01(\tH\x00\x12\x11\n\x07\x61s_bool\x18\x02 \x01(\x08H\x00\x42\x07\n\x05value\">\n\x0eRecoverRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\"%\n\x0fRecoverResponse\x12\x12\n\nnot_needed\x18\x01 \x01(\x08\"?\n\x0fOptimizeRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\"\x12\n\x10OptimizeResponse\"\x88\x01\n\x12ResetCachesRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x31\n\x06\x63\x61\x63hes\x18\x02 \x03(\x0e\x32!.hgitaly.ResetCachesRequest.Cache\"\x11\n\x05\x43\x61\x63he\x12\x08\n\x04TAGS\x10\x00\"\x15\n\x13ResetCachesResponse\"b\n\rMercurialPeer\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\x0f\n\x07ssh_key\x18\x05 \x01(\t\x12\x17\n\x0fssh_known_hosts\x18\x06 \x01(\t\x12\x1a\n\x12ssh_remote_command\x18\x07 \x01(\x0c\"\xa7\x01\n\x0bPushRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12+\n\x0bremote_peer\x18\x02 \x01(\x0b\x32\x16.hgitaly.MercurialPeer\x12%\n\x1donly_gitlab_branches_matching\x18\x03 \x03(\x0c\x12\x16\n\x0einclude_drafts\x18\x04 \x01(\x08\"&\n\x0cPushResponse\x12\x16\n\x0enew_changesets\x18\x01 \x01(\x08\"\xb8\x01\n\x0bPullRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12+\n\x0bremote_peer\x18\x02 \x01(\x0b\x32\x16.hgitaly.MercurialPeer\x12\x1a\n\x04user\x18\x04 \x01(\x0b\x32\x0c.gitaly.User\x12\x1b\n\x13mercurial_revisions\x18\x05 \x03(\x0cJ\x04\x08\x03\x10\x04R\x0fgitlab_branches\"&\n\x0cPullResponse\x12\x16\n\x0enew_changesets\x18\x01 \x01(\x08\"g\n\rHgCallRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x1a\n\x04user\x18\x02 \x01(\x0b\x32\x0c.gitaly.User\x12\x0c\n\x04\x61rgs\x18\x03 \x03(\x0c\"3\n\x0eHgCallResponse\x12\x11\n\texit_code\x18\x01 \x01(\x05\x12\x0e\n\x06stdout\x18\x02 \x03(\x0c*&\n\x0e\x43onfigItemType\x12\n\n\x06STRING\x10\x00\x12\x08\n\x04\x42OOL\x10\x01\x32\xa5\x06\n\x1aMercurialRepositoryService\x12M\n\nInitConfig\x12\x1a.hgitaly.InitConfigRequest\x1a\x1b.hgitaly.InitConfigResponse\"\x06\xfa\x97(\x02\x08\x01\x12V\n\rGetConfigItem\x12\x1d.hgitaly.GetConfigItemRequest\x1a\x1e.hgitaly.GetConfigItemResponse\"\x06\xfa\x97(\x02\x08\x02\x12\x44\n\x07Recover\x12\x17.hgitaly.RecoverRequest\x1a\x18.hgitaly.RecoverResponse\"\x06\xfa\x97(\x02\x08\x02\x12G\n\x08Optimize\x12\x18.hgitaly.OptimizeRequest\x1a\x19.hgitaly.OptimizeResponse\"\x06\xfa\x97(\x02\x08\x01\x12P\n\x0bResetCaches\x12\x1b.hgitaly.ResetCachesRequest\x1a\x1c.hgitaly.ResetCachesResponse\"\x06\xfa\x97(\x02\x08\x01\x12\x43\n\x06HgCall\x12\x16.hgitaly.HgCallRequest\x1a\x17.hgitaly.HgCallResponse\"\x06\xfa\x97(\x02\x08\x01\x30\x01\x12_\n\x10GetManagedConfig\x12 .hgitaly.GetManagedConfigRequest\x1a!.hgitaly.GetManagedConfigResponse\"\x06\xfa\x97(\x02\x08\x02\x12_\n\x10SetManagedConfig\x12 .hgitaly.SetManagedConfigRequest\x1a!.hgitaly.SetManagedConfigResponse\"\x06\xfa\x97(\x02\x08\x01\x12;\n\x04Push\x12\x14.hgitaly.PushRequest\x1a\x15.hgitaly.PushResponse\"\x06\xfa\x97(\x02\x08\x01\x12;\n\x04Pull\x12\x14.hgitaly.PullRequest\x1a\x15.hgitaly.PullResponse\"\x06\xfa\x97(\x02\x08\x01\x62\x06proto3')
18
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x1amercurial-repository.proto\x12\x07hgitaly\x1a\nlint.proto\x1a\x0cshared.proto\"Y\n\x11InitConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x16\n\x0enamespace_path\x18\x02 \x01(\t\"\x14\n\x12InitConfigResponse\"\x95\x02\n\x15HeptapodConfigSection\x12!\n\x14\x61llow_multiple_heads\x18\x02 \x01(\x08H\x00\x88\x01\x01\x12\x1c\n\x0f\x61llow_bookmarks\x18\x03 \x01(\x08H\x01\x88\x01\x01\x12\x45\n\x0c\x61uto_publish\x18\x04 \x01(\x0e\x32*.hgitaly.HeptapodConfigSection.AutoPublishH\x02\x88\x01\x01\"6\n\x0b\x41utoPublish\x12\x11\n\rWITHOUT_TOPIC\x10\x00\x12\x0b\n\x07NOTHING\x10\x01\x12\x07\n\x03\x41LL\x10\x02\x42\x17\n\x15_allow_multiple_headsB\x12\n\x10_allow_bookmarksB\x0f\n\r_auto_publish\"V\n\x17GetManagedConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\r\n\x05local\x18\x02 \x01(\x08\"]\n\x18GetManagedConfigResponse\x12\x0f\n\x07inherit\x18\x01 \x01(\x08\x12\x30\n\x08heptapod\x18\x02 \x01(\x0b\x32\x1e.hgitaly.HeptapodConfigSection\"\xc2\x01\n\x17SetManagedConfigRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x14\n\x07inherit\x18\x02 \x01(\x08H\x00\x88\x01\x01\x12\x30\n\x08heptapod\x18\x03 \x01(\x0b\x32\x1e.hgitaly.HeptapodConfigSection\x12\x14\n\x0cremove_items\x18\x04 \x03(\t\x12\x0f\n\x07\x62y_line\x18\x05 \x01(\tB\n\n\x08_inherit\"\x1a\n\x18SetManagedConfigResponse\"\x8d\x01\n\x14GetConfigItemRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12(\n\x07\x61s_type\x18\x02 \x01(\x0e\x32\x17.hgitaly.ConfigItemType\x12\x0f\n\x07section\x18\x03 \x01(\t\x12\x0c\n\x04name\x18\x04 \x01(\t\"H\n\x15GetConfigItemResponse\x12\x13\n\tas_string\x18\x01 \x01(\tH\x00\x12\x11\n\x07\x61s_bool\x18\x02 \x01(\x08H\x00\x42\x07\n\x05value\">\n\x0eRecoverRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\"%\n\x0fRecoverResponse\x12\x12\n\nnot_needed\x18\x01 \x01(\x08\"?\n\x0fOptimizeRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\"\x12\n\x10OptimizeResponse\"\x88\x01\n\x12ResetCachesRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x31\n\x06\x63\x61\x63hes\x18\x02 \x03(\x0e\x32!.hgitaly.ResetCachesRequest.Cache\"\x11\n\x05\x43\x61\x63he\x12\x08\n\x04TAGS\x10\x00\"\x15\n\x13ResetCachesResponse\"b\n\rMercurialPeer\x12\x0b\n\x03url\x18\x01 \x01(\t\x12\x0f\n\x07ssh_key\x18\x05 \x01(\t\x12\x17\n\x0fssh_known_hosts\x18\x06 \x01(\t\x12\x1a\n\x12ssh_remote_command\x18\x07 \x01(\x0c\"\xa7\x01\n\x0bPushRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12+\n\x0bremote_peer\x18\x02 \x01(\x0b\x32\x16.hgitaly.MercurialPeer\x12%\n\x1donly_gitlab_branches_matching\x18\x03 \x03(\x0c\x12\x16\n\x0einclude_drafts\x18\x04 \x01(\x08\"&\n\x0cPushResponse\x12\x16\n\x0enew_changesets\x18\x01 \x01(\x08\"\xb8\x01\n\x0bPullRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12+\n\x0bremote_peer\x18\x02 \x01(\x0b\x32\x16.hgitaly.MercurialPeer\x12\x1a\n\x04user\x18\x04 \x01(\x0b\x32\x0c.gitaly.User\x12\x1b\n\x13mercurial_revisions\x18\x05 \x03(\x0cJ\x04\x08\x03\x10\x04R\x0fgitlab_branches\"&\n\x0cPullResponse\x12\x16\n\x0enew_changesets\x18\x01 \x01(\x08\"g\n\rHgCallRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x1a\n\x04user\x18\x02 \x01(\x0b\x32\x0c.gitaly.User\x12\x0c\n\x04\x61rgs\x18\x03 \x03(\x0c\"3\n\x0eHgCallResponse\x12\x11\n\texit_code\x18\x01 \x01(\x05\x12\x0e\n\x06stdout\x18\x02 \x03(\x0c\"\xc2\x01\n\x13HousekeepingRequest\x12,\n\nrepository\x18\x01 \x01(\x0b\x32\x12.gitaly.RepositoryB\x04\x98\xc6,\x01\x12\x0c\n\x04\x66\x61il\x18\x02 \x01(\x08\x12\x0f\n\x07recover\x18\x03 \x01(\x08\x12\x31\n)working_directories_age_threshold_seconds\x18\x04 \x01(\r\x12+\n#working_directories_remove_unlisted\x18\x05 \x01(\x08\"\xa3\x01\n\x14HousekeepingResponse\x12\x13\n\x0brecover_run\x18\x01 \x01(\x08\x12)\n!recovered_interrupted_transaction\x18\x02 \x01(\x08\x12\x1e\n\x16working_directories_gc\x18\x03 \x01(\x08\x12+\n#working_directories_remove_unlisted\x18\x04 \x01(\x08*&\n\x0e\x43onfigItemType\x12\n\n\x06STRING\x10\x00\x12\x08\n\x04\x42OOL\x10\x01\x32\xfa\x06\n\x1aMercurialRepositoryService\x12M\n\nInitConfig\x12\x1a.hgitaly.InitConfigRequest\x1a\x1b.hgitaly.InitConfigResponse\"\x06\xfa\x97(\x02\x08\x01\x12V\n\rGetConfigItem\x12\x1d.hgitaly.GetConfigItemRequest\x1a\x1e.hgitaly.GetConfigItemResponse\"\x06\xfa\x97(\x02\x08\x02\x12\x44\n\x07Recover\x12\x17.hgitaly.RecoverRequest\x1a\x18.hgitaly.RecoverResponse\"\x06\xfa\x97(\x02\x08\x02\x12G\n\x08Optimize\x12\x18.hgitaly.OptimizeRequest\x1a\x19.hgitaly.OptimizeResponse\"\x06\xfa\x97(\x02\x08\x01\x12P\n\x0bResetCaches\x12\x1b.hgitaly.ResetCachesRequest\x1a\x1c.hgitaly.ResetCachesResponse\"\x06\xfa\x97(\x02\x08\x01\x12\x43\n\x06HgCall\x12\x16.hgitaly.HgCallRequest\x1a\x17.hgitaly.HgCallResponse\"\x06\xfa\x97(\x02\x08\x01\x30\x01\x12_\n\x10GetManagedConfig\x12 .hgitaly.GetManagedConfigRequest\x1a!.hgitaly.GetManagedConfigResponse\"\x06\xfa\x97(\x02\x08\x02\x12_\n\x10SetManagedConfig\x12 .hgitaly.SetManagedConfigRequest\x1a!.hgitaly.SetManagedConfigResponse\"\x06\xfa\x97(\x02\x08\x01\x12;\n\x04Push\x12\x14.hgitaly.PushRequest\x1a\x15.hgitaly.PushResponse\"\x06\xfa\x97(\x02\x08\x01\x12;\n\x04Pull\x12\x14.hgitaly.PullRequest\x1a\x15.hgitaly.PullResponse\"\x06\xfa\x97(\x02\x08\x01\x12S\n\x0cHousekeeping\x12\x1c.hgitaly.HousekeepingRequest\x1a\x1d.hgitaly.HousekeepingResponse\"\x06\xfa\x97(\x02\x08\x01\x62\x06proto3')
19
19
 
20
20
  _globals = globals()
21
21
  _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -43,6 +43,8 @@ if _descriptor._USE_C_DESCRIPTORS == False:
43
43
  _PULLREQUEST.fields_by_name['repository']._serialized_options = b'\230\306,\001'
44
44
  _HGCALLREQUEST.fields_by_name['repository']._options = None
45
45
  _HGCALLREQUEST.fields_by_name['repository']._serialized_options = b'\230\306,\001'
46
+ _HOUSEKEEPINGREQUEST.fields_by_name['repository']._options = None
47
+ _HOUSEKEEPINGREQUEST.fields_by_name['repository']._serialized_options = b'\230\306,\001'
46
48
  _MERCURIALREPOSITORYSERVICE.methods_by_name['InitConfig']._options = None
47
49
  _MERCURIALREPOSITORYSERVICE.methods_by_name['InitConfig']._serialized_options = b'\372\227(\002\010\001'
48
50
  _MERCURIALREPOSITORYSERVICE.methods_by_name['GetConfigItem']._options = None
@@ -63,8 +65,10 @@ if _descriptor._USE_C_DESCRIPTORS == False:
63
65
  _MERCURIALREPOSITORYSERVICE.methods_by_name['Push']._serialized_options = b'\372\227(\002\010\001'
64
66
  _MERCURIALREPOSITORYSERVICE.methods_by_name['Pull']._options = None
65
67
  _MERCURIALREPOSITORYSERVICE.methods_by_name['Pull']._serialized_options = b'\372\227(\002\010\001'
66
- _globals['_CONFIGITEMTYPE']._serialized_start=2129
67
- _globals['_CONFIGITEMTYPE']._serialized_end=2167
68
+ _MERCURIALREPOSITORYSERVICE.methods_by_name['Housekeeping']._options = None
69
+ _MERCURIALREPOSITORYSERVICE.methods_by_name['Housekeeping']._serialized_options = b'\372\227(\002\010\001'
70
+ _globals['_CONFIGITEMTYPE']._serialized_start=2492
71
+ _globals['_CONFIGITEMTYPE']._serialized_end=2530
68
72
  _globals['_INITCONFIGREQUEST']._serialized_start=65
69
73
  _globals['_INITCONFIGREQUEST']._serialized_end=154
70
74
  _globals['_INITCONFIGRESPONSE']._serialized_start=156
@@ -113,6 +117,10 @@ if _descriptor._USE_C_DESCRIPTORS == False:
113
117
  _globals['_HGCALLREQUEST']._serialized_end=2074
114
118
  _globals['_HGCALLRESPONSE']._serialized_start=2076
115
119
  _globals['_HGCALLRESPONSE']._serialized_end=2127
116
- _globals['_MERCURIALREPOSITORYSERVICE']._serialized_start=2170
117
- _globals['_MERCURIALREPOSITORYSERVICE']._serialized_end=2975
120
+ _globals['_HOUSEKEEPINGREQUEST']._serialized_start=2130
121
+ _globals['_HOUSEKEEPINGREQUEST']._serialized_end=2324
122
+ _globals['_HOUSEKEEPINGRESPONSE']._serialized_start=2327
123
+ _globals['_HOUSEKEEPINGRESPONSE']._serialized_end=2490
124
+ _globals['_MERCURIALREPOSITORYSERVICE']._serialized_start=2533
125
+ _globals['_MERCURIALREPOSITORYSERVICE']._serialized_end=3423
118
126
  # @@protoc_insertion_point(module_scope)