1. TortoiseHg
  2. TortoiseHg
  3. thg
Issue #2565 duplicate

RevlogError: integrity check failed on histedit

Esben Skovenborg
created an issue

I received this traceback when a "hg histedit" (changing a single commit message) was completing, while having the thg workbench open with the same repo. Although RevlogError doesn't sound good, "hg verify" does not report any errors.

Could it be some kind of timing issue - i.e. thg checking the status (log) at some unfortunate point in time where command-line hg histedit is messing with the history...?

    #!python
    ** Mercurial version (2.5.4).  TortoiseHg version (2.7.1)
    ** Command: log
    ** CWD: /home/xxx/yyy
    ** Encoding: UTF-8
    ** Extensions loaded: convert, rebase, transplant, histedit, svn, hggit, largefiles
    ** Python version: 2.7.3 (default, Sep 26 2012, 21:51:14) [GCC 4.7.2]
    ** System: Linux XXX 3.5.0-27-generic #46-Ubuntu SMP Mon Mar 25 19:58:17 UTC 2013 x86_64
    ** Qt-4.8.2 PyQt-4.9.3 QScintilla-2.6.2
    Traceback (most recent call last):
      File "/usr/lib/python2.7/dist-packages/tortoisehg/hgqt/status.py", line 565, in run
        wctx.status(**stopts)
      File "/usr/lib/python2.7/dist-packages/mercurial/context.py", line 946, in status
        stat = self._repo.status(ignored=ignored, clean=clean, unknown=unknown)
      File "/usr/lib/python2.7/dist-packages/mercurial/localrepo.py", line 58, in wrapper
        return orig(repo.unfiltered(), *args, **kwargs)
      File "/usr/lib/python2.7/dist-packages/hgext/largefiles/reposetup.py", line 209, in status
        for standin in ctx1.manifest():
      File "/usr/lib/python2.7/dist-packages/mercurial/context.py", line 180, in manifest
        return self._manifest
      File "/usr/lib/python2.7/dist-packages/mercurial/util.py", line 246, in __get__
        result = self.func(obj)
      File "/usr/lib/python2.7/dist-packages/mercurial/context.py", line 150, in _manifest
        return self._repo.manifest.read(self._changeset[0])
      File "/usr/lib/python2.7/dist-packages/mercurial/util.py", line 246, in __get__
        result = self.func(obj)
      File "/usr/lib/python2.7/dist-packages/mercurial/context.py", line 146, in _changeset
        return self._repo.changelog.read(self.rev())
      File "/usr/lib/python2.7/dist-packages/mercurial/changelog.py", line 282, in read
        text = self.revision(node)
      File "/usr/lib/python2.7/dist-packages/mercurial/revlog.py", line 931, in revision
        text = self._checkhash(text, node, rev)
      File "/usr/lib/python2.7/dist-packages/mercurial/revlog.py", line 940, in _checkhash
        % (self.indexfile, rev))
    RevlogError: integrity check failed on 00changelog.i:2780

Comments (11)

  1. Zane Purvis

    I got a similar message while trying to push to an svn repo.

    I have a bookmark (which is a branch off of what svn considers "trunk") and had done a histedit on that bookmark to fold some changesets together which failed and I cleaned up by removing .hg/histedit-state. I had several changesets that were on a branch that forked off at the same point as the bookmark, and this was the tip and the head I was working on at the time of the push.

    It looks like my SVN server is fine and hg verify didn't report any errors.

    ** Mercurial version (2.6).  TortoiseHg version (2.8)
    ** Command: 
    ** CWD: c:\Users\Zane.Purvis\Code\iperl\iperl_with_asic_fw_hg
    ** Encoding: cp1252
    ** Extensions loaded: mercurial_keyring, zeroconf, svn, rebase, graphlog, purge, hgcr-gui-qt, histedit, extdiff
    ** Python version: 2.7.3 (default, Apr 10 2012, 23:31:26) [MSC v.1500 32 bit (Intel)]
    ** Windows version: sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1')
    ** Processor architecture: x86
    ** Qt-4.8.4 PyQt-4.9.6 QScintilla-2.7
    Traceback (most recent call last):
      File "tortoisehg\hgqt\commit.pyo", line 584, in repositoryChanged
      File "tortoisehg\hgqt\commit.pyo", line 601, in refresh
      File "tortoisehg\hgqt\thgrepo.pyo", line 630, in thgmqappliedpatch
      File "tortoisehg\hgqt\thgrepo.pyo", line 622, in _thgmqpatchtags
      File "mercurial\context.pyo", line 205, in tags
      File "mercurial\localrepo.pyo", line 618, in nodetags
      File "mercurial\util.pyo", line 277, in __get__
      File "mercurial\localrepo.pyo", line 541, in _tagscache
      File "mercurial\localrepo.pyo", line 578, in _findtags
      File "mercurial\tags.pyo", line 30, in findglobaltags
      File "mercurial\tags.pyo", line 248, in _readtagcache
      File "mercurial\context.pyo", line 308, in filenode
      File "mercurial\context.pyo", line 296, in _fileinfo
      File "mercurial\context.pyo", line 195, in files
      File "mercurial\util.pyo", line 277, in __get__
      File "mercurial\context.pyo", line 146, in _changeset
      File "mercurial\changelog.pyo", line 282, in read
      File "mercurial\revlog.pyo", line 934, in revision
      File "mercurial\revlog.pyo", line 943, in _checkhash
    RevlogError: integrity check failed on 00changelog.i:485
    
  2. Yuya Nishihara

    Could it be some kind of timing issue - i.e. thg checking the status (log) at some unfortunate point in time where command-line hg histedit is messing with the history...?

    I guess so. TortoiseHg tries reloading when repository is unlocked, but hg may lock and rewrite the history immediately after unlock.

    while trying to push to an svn repo.

    Could be #1469 or #2470.

  3. Marc Schlaich

    I'm getting a similar error if rewording a single changeset:

        #!python
        ** Mercurial version (2.6.1).  TortoiseHg version (2.8+54-d59b1b635d5d)
        ** Command: 
        ** CWD: D:\Projekte\thg
        ** Encoding: cp1252
        ** Extensions loaded: transplant, histedit, rebase
        ** Python version: 2.7.5 (default, May 15 2013, 22:43:36) [MSC v.1500 32 bit (Intel)]
        ** Windows version: sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1')
        ** Processor architecture: x64
        ** Qt-4.8.4 PyQt-4.10.1 QScintilla-2.7.1
        Traceback (most recent call last):
          File "D:\Projekte\thg\tortoisehg\hgqt\commit.py", line 589, in repositoryChanged
            self.refresh()
          File "D:\Projekte\thg\tortoisehg\hgqt\commit.py", line 606, in refresh
            ispatch = self.repo.changectx('.').thgmqappliedpatch()
          File "D:\Projekte\thg\tortoisehg\hgqt\thgrepo.py", line 618, in thgmqappliedpatch
            return self.rev() is not None and bool(self._thgmqpatchtags())
          File "D:\Projekte\thg\tortoisehg\hgqt\thgrepo.py", line 610, in _thgmqpatchtags
            mytags = set(self.tags())
          File "c:\Python27\lib\site-packages\mercurial\context.py", line 205, in tags
            return self._repo.nodetags(self._node)
          File "c:\Python27\lib\site-packages\mercurial\localrepo.py", line 618, in nodetags
            if not self._tagscache.nodetagscache:
          File "c:\Python27\lib\site-packages\mercurial\util.py", line 277, in __get__
            result = self.func(obj)
          File "c:\Python27\lib\site-packages\mercurial\localrepo.py", line 541, in _tagscache
            cache.tags, cache.tagtypes = self._findtags()
          File "c:\Python27\lib\site-packages\mercurial\localrepo.py", line 578, in _findtags
            tagsmod.findglobaltags(self.ui, self, alltags, tagtypes)
          File "c:\Python27\lib\site-packages\mercurial\tags.py", line 30, in findglobaltags
            (heads, tagfnode, cachetags, shouldwrite) = _readtagcache(ui, repo)
          File "c:\Python27\lib\site-packages\mercurial\tags.py", line 248, in _readtagcache
            fnode = cctx.filenode('.hgtags')
          File "c:\Python27\lib\site-packages\mercurial\context.py", line 308, in filenode
            return self._fileinfo(path)[0]
          File "c:\Python27\lib\site-packages\mercurial\context.py", line 296, in _fileinfo
            if '_manifestdelta' in self.__dict__ or path in self.files():
          File "c:\Python27\lib\site-packages\mercurial\context.py", line 195, in files
            return self._changeset[3]
          File "c:\Python27\lib\site-packages\mercurial\util.py", line 277, in __get__
            result = self.func(obj)
          File "c:\Python27\lib\site-packages\mercurial\context.py", line 146, in _changeset
            return self._repo.changelog.read(self.rev())
          File "c:\Python27\lib\site-packages\mercurial\changelog.py", line 282, in read
            text = self.revision(node)
          File "c:\Python27\lib\site-packages\mercurial\revlog.py", line 929, in revision
            text = str(self._chunkbase(base))
          File "c:\Python27\lib\site-packages\mercurial\revlog.py", line 852, in _chunkbase
            return self._chunk(rev)
          File "c:\Python27\lib\site-packages\mercurial\revlog.py", line 849, in _chunk
            return decompress(self._chunkraw(rev, rev))
          File "c:\Python27\lib\site-packages\mercurial\revlog.py", line 89, in decompress
            raise RevlogError(_("revlog decompress error: %s") % str(e))
        RevlogError: revlog decompress error: Error -5 while decompressing data: incomplete or truncated stream
    
  4. Marc Schlaich

    Issue with histedit seems to be fixed with one of the latest changes on "default". Not sure which one, though :)

    This statement is wrong. The issue was gone as regression from #3298. Now I'm seeing it again.

  5. Log in to comment