Comments
Patch
@@ -30,10 +30,11 @@ class bundlerevlog(revlog.revlog):
#
revlog.revlog.__init__(self, opener, indexfile)
self.bundle = bundle
self.basemap = {}
n = len(self)
+ self.disktiprev = n - 1
chain = None
self.bundlenodes = []
while True:
chunkdata = bundle.deltachunk(chain)
if not chunkdata:
@@ -282,13 +283,15 @@ class bundlerepository(localrepo.localre
return bundlepeer(self)
def getcwd(self):
return os.getcwd() # always outside the repo
- def _writebranchcache(self, branches, tip, tiprev):
- # don't overwrite the disk cache with bundle-augmented data
- pass
+ def _cacheabletip(self):
+ # we should not cache data from the bundle on disk
+ ret = super(bundlerepository, self)._cacheabletip()
+ return min(self.changelog.disktiprev, ret)
+
def instance(ui, path, create):
if create:
raise util.Abort(_('cannot create new bundle repository'))
parentpath = ui.config("bundle", "mainreporoot", "")