Issue1184

Title hg recover does not fully recover database
Priority bug Status chatting
Superseder Nosy List ipse, jack, mpm
Assigned To Topics

Created on 2008-06-18.10:01:28 by ipse, last changed 2008-06-18.16:03:29 by ipse.

Messages
msg6337 (view) Author: ipse Date: 2008-06-18.16:03:27
This helped, thanks!

Though I hope this problem will be fixed and will not require manual
intervention in future. :)

PS I also found that clonning to VirtualBox shared folder, mapped to drive
letter, does not work in Windows XP guest. Should I report this as bug?
msg6336 (view) Author: mpm Date: 2008-06-18.15:20:52
Hmm, that's very peculiar. Here's what you should do:

hg clone -r 32 busted-repo clean-repo

That will copy all the changesets up to the broken one. Then you can either copy
your working dir changes over to the clean repo, or you can do a shell game in
the busted repo by moving .hg to .hg-busted, and copying .hg from the clean repo.
msg6334 (view) Author: ipse Date: 2008-06-18.15:04:30
> Also, for future reference, simply quitting your editor with no changes will
> abort a commit. And an immediate hg rollback will undo an accidental commit.

Yeah, I know that quitting editor without saving will abort commit. But that
time I was in doubt - should I just exit with no changes or delete all non-HG:
lines (there were some initial check in comments not starting with HG:). And at
that moment I forgot about rollback.. I'm still not got used to all hg features.
msg6333 (view) Author: ipse Date: 2008-06-18.15:01:11
>hg debugindex .hg/store/00manifest.i
   rev    offset  length   base linkrev nodeid       p1           p2
     0         0  102213      0       0 19734ed7b462 000000000000 000000000000
     1    102213      63      0       1 8fdac5a0d46d 19734ed7b462 000000000000
     2    102276      63      0       2 485d56df0ac2 8fdac5a0d46d 000000000000
     3    102339     148      0       3 c54ad32eea72 8fdac5a0d46d 000000000000
     4    102487     101      0       4 f9755ac503b9 c54ad32eea72 000000000000
     5    102588      63      0       5 5cddbbc3d0c9 485d56df0ac2 f9755ac503b9
     6    102651     146      0       6 62765f8ebf18 5cddbbc3d0c9 000000000000
     7    102797     128      0       7 a4a88e0d0ba4 62765f8ebf18 000000000000
     8    102925      61      0       8 b3dde3c462eb a4a88e0d0ba4 000000000000
     9    102986      61      0       9 f17fecfd6ada b3dde3c462eb 000000000000
    10    103047     129      0      10 e50161398499 f17fecfd6ada 000000000000
    11    103176      84      0      11 746cf0d78702 e50161398499 000000000000
    12    103260      86      0      12 6831f5d80e63 746cf0d78702 000000000000
    13    103346      96      0      13 9c6768e20f81 6831f5d80e63 000000000000
    14    103442     388      0      14 bc108bcb440b 9c6768e20f81 000000000000
    15    103830     376      0      15 3a1cf9b12c96 bc108bcb440b 000000000000
    16    104206      61      0      16 0e90962bd3a9 3a1cf9b12c96 000000000000
    17    104267      63      0      17 462fcf3cb50a 0e90962bd3a9 000000000000
    18    104330      87      0      18 7824f9d748a7 462fcf3cb50a 000000000000
    19    104417     147      0      19 8b247eecbe74 7824f9d748a7 000000000000
    20    104564     145      0      20 e17d21c0e702 8b247eecbe74 000000000000
    21    104709      87      0      21 906f8761d812 e17d21c0e702 000000000000
    22    104796     286      0      22 18735436312a 906f8761d812 000000000000
    23    105082    1178      0      23 4587f3fef337 5cddbbc3d0c9 000000000000
    24    106260    1234      0      24 43c74e3bcc83 18735436312a 4587f3fef337
    25    107494     560      0      25 d43dc93b0130 43c74e3bcc83 000000000000
    26    108054     280      0      26 d14533260172 d43dc93b0130 000000000000
    27    108334      89      0      27 c02ee9b82296 d14533260172 000000000000
    28    108423     391      0      28 0421a794b664 c02ee9b82296 000000000000
    29    108814     324      0      29 ce7fa70ab869 0421a794b664 000000000000
    30    109138     151      0      30 f8a1759a59e8 ce7fa70ab869 000000000000
    31    109289      78      0      31 745df44e69a8 f8a1759a59e8 000000000000
    32    109367     152      0      32 fe99d83235db 745df44e69a8 000000000000
    33         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    34         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    35         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    36         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    37         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    38         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    39         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    40         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    41         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    42         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    43         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    44         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    45         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    46         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    47         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    48         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    49         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    50         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    51         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    52         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    53         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    54         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    55         0       0      0       0 000000000000 19734ed7b462 19734ed7b462
    56         0  102257      0      33 d90d295d87c0 4587f3fef337 000000000000
msg6332 (view) Author: mpm Date: 2008-06-18.14:48:55
Also, for future reference, simply quitting your editor with no changes will
abort a commit. And an immediate hg rollback will undo an accidental commit.
msg6331 (view) Author: mpm Date: 2008-06-18.14:47:52
Send the output of

hg debugindex .hg/store/00manifest.i
msg6330 (view) Author: ipse Date: 2008-06-18.14:38:16
>hg verify
checking changesets
checking manifests
 manifest@?: data length off by 109519 bytes
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 0: duplicates manifest from 0
 33: reading manifest delta: need more than 1 value to unpack
crosschecking files in changesets and manifests
checking files
3181 files, 34 changesets, 3254 total revisions
24 integrity errors encountered!
msg6329 (view) Author: mpm Date: 2008-06-18.14:23:48
What's hg verify say?
msg6319 (view) Author: ipse Date: 2008-06-18.10:01:25
I killed hg process in the middle of process of commit (it was waiting for
commit message to be entered), so database was left in corrupted state. As hg
suggested, I ran 'hg recover', but it did not helped. After any command I see
this output on console:

>hg up -C ipse-local
** unknown exception encountered, details follow
** report bug details to http://www.selenic.com/mercurial/bts
** or mercurial@selenic.com
** Mercurial Distributed SCM (version 1.0.1+20080525)
Traceback (most recent call last):
  File "hg", line 20, in <module>
  File "mercurial\dispatch.pyc", line 20, in run
  File "mercurial\dispatch.pyc", line 29, in dispatch
  File "mercurial\dispatch.pyc", line 45, in _runcatch
  File "mercurial\dispatch.pyc", line 364, in _dispatch
  File "mercurial\dispatch.pyc", line 417, in _runcommand
  File "mercurial\dispatch.pyc", line 373, in checkargs
  File "mercurial\dispatch.pyc", line 356, in <lambda>
  File "mercurial\commands.pyc", line 2798, in update
  File "mercurial\hg.pyc", line 287, in clean
  File "mercurial\merge.pyc", line 352, in update
  File "mercurial\localrepo.pyc", line 485, in changectx
  File "mercurial\context.pyc", line 28, in __init__
  File "mercurial\localrepo.pyc", line 452, in lookup
  File "mercurial\localrepo.pyc", line 286, in tags
  File "mercurial\localrepo.pyc", line 332, in _hgtagsnodes
  File "mercurial\context.pyc", line 116, in filenode
  File "mercurial\context.pyc", line 108, in _fileinfo
  File "mercurial\manifest.pyc", line 110, in find
  File "mercurial\revlog.pyc", line 952, in revision
mpatch.mpatchError: patch cannot be decoded

How can I get this repo working again? It would be sad to lose all my overnight
work becacuse of Mercurial. And in general it is bad that Mercurial is not as
safe to use, as svn.

PS This is under Windows XP.
History
Date User Action Args
2008-06-18 16:03:29ipsesetnosy: mpm, ipse, jack
messages: + msg6337
2008-06-18 15:20:52mpmsetnosy: mpm, ipse, jack
messages: + msg6336
2008-06-18 15:04:31ipsesetnosy: mpm, ipse, jack
messages: + msg6334
2008-06-18 15:01:15ipsesetnosy: mpm, ipse, jack
messages: + msg6333
2008-06-18 14:48:56mpmsetnosy: mpm, ipse, jack
messages: + msg6332
2008-06-18 14:47:52mpmsetnosy: mpm, ipse, jack
messages: + msg6331
2008-06-18 14:38:16ipsesetnosy: mpm, ipse, jack
messages: + msg6330
2008-06-18 14:36:51jacksetnosy: + jack
2008-06-18 14:23:50mpmsetstatus: unread -> chatting
nosy: + mpm
messages: + msg6329
2008-06-18 10:01:28ipsecreate