dirstat missing a lot of files?

Matt Cross matt.cross at gmail.com
Tue Apr 1 19:50:03 UTC 2008


I'm not sure how my repository got in this state, but somehow the dirstate
lost track of most of the files in my repository.  It took me a while to
figure out what was going on as 'hg status' showed that files that I knew
were tracked were not in the repository (with a '?' in front of the
filename), but 'hg log' and 'hg manifest' both reported valid information,
and 'hg verify' did not report any errors.

I finally ran across references to dirstate, and found this:

[mcross at localhost toolchain]$ hg manifest | wc -l
94267
[mcross at localhost toolchain]$ hg debugstate | wc -l
5331

An 'hg debugrebuildstate' seemed to restore sanity to my repository.

Does anyone have any idea how this could have happened to my repository,
what I should look out for, or any ideas for how to reproduce the problem?
Would it make sense to add dirstate checking to 'hg verify' to help catch
this condition?

    -Matt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurial-scm.org/pipermail/mercurial/attachments/20080401/c47221eb/attachment-0001.html>


More information about the Mercurial mailing list