Abort: no match found!

Matt Mackall mpm at selenic.com
Tue Mar 11 12:45:03 CDT 2008

Peter Arrenbrecht wrote:
> On Tue, Mar 11, 2008 at 2:14 AM, Matt Mackall <mpm at selenic.com> wrote:
>>  On Mon, 2008-03-10 at 16:35 -0500, Brad Miller wrote:
>>  > After removing via hg rm  a couple of large directories  from my
>>  > project today I now get the following error message when I try to
>>  > commit or stat my project.
>>  >
>>  > bmiller at cray> hg stat
>>  > abort: No match found!
>>  Run that again with --traceback and --debug, please.
>>  > [255] bmiller at cray> hg verify
>>  > checking changesets
>>  > checking manifests
>>  > crosschecking files in changesets and manifests
>>  > checking files
>>  >   .DS_Store at 0: 727ee90a3730 in manifests not found
>>  >   ClassPlan.oo3/.OABK at 0: b80de5d13875 in manifests not found
>>  >   Code/jPhoto/Library/.DS_Store at 0: f26d0837f265 in manifests not found
>>  >   ExternalResources/corejava/.DS_Store at 0: 9e7bae44a5a5 in manifests
>>  > not found
>>  > 1276 files, 49 changesets, 1372 total revisions
>>  > 4 integrity errors encountered!
>>  First thing to know is this has absolutely nothing to do with the above
>>  problem. 'verify' checks the contents of the repository only and doesn't
>>  look at the working directory at all.
>>  The above is saying "at some point you checked in a file called x, and
>>  now that seems to be missing". For every file ever checked in, there's a
>>  file in .hg/store/data/path/to/file.i (and sometimes .d) where that
>>  file's data is stored. And I suspect the corresponding files have gone
>>  missing.
>>  My suspicion is that you did something silly like "find -name
>>  '.DS_Store' | xargs rm". Oops.
> Been there too. :(
>>  Normally, you could mostly recover by truncating your history back to
>>  the point where the corruption occurred. But these files were all in
>>  revision 0 (the "@0" bit) at the beginning of your history.
> I was at the time nearly able to recover it by copying missing files
> from an older backup of the repo. So now I'm thinking: wouldn't a
> command that fixes a repo by restoring accidentally deleted store data
> from an older backup be handy? Can this be done? My understanding of
> the store would say yes. I might give this a try, but if anyone knows
> right away it cannot be done, please tell me before I waste time.

You can just copy the missing revlogs back into place, yes.

In fact, if you don't have missing revlogs, but you have the missing 
file revisions, you may be able to check them into a scratch repo and 
copy them back.

Mathematics is the supreme nostalgia of our time.

More information about the Mercurial mailing list