store: do not drop the final `/` when creating manifestlog instance
authorPierre-Yves David <pierre-yves.david@octobus.net>
Mon, 29 May 2023 13:28:33 +0200
changeset 50628 3ea3767c23a4
parent 50627 e1ee6910f6bc
child 50629 309cbd8400ae
store: do not drop the final `/` when creating manifestlog instance This bug, inherited from the upgrade code leads to the acces/creation of broken revlog with name `DIRECTORY00manifest.i` instead of `DIRECTORY/00manifest.i` We fix it in its own changeset to preserve the "pure code movement" aspect of the previous changesets.
mercurial/store.py
--- a/mercurial/store.py	Sat May 27 04:01:17 2023 +0200
+++ b/mercurial/store.py	Mon May 29 13:28:33 2023 +0200
@@ -554,7 +554,7 @@
         if self.is_changelog:
             return changelog.changelog(repo.svfs)
         elif self.is_manifestlog:
-            mandir = self.target_id.rstrip(b'/')
+            mandir = self.target_id
             return manifest.manifestrevlog(
                 repo.nodeconstants, repo.svfs, tree=mandir
             )