Commit Graph

62 Commits

Author SHA1 Message Date
Matt Mackall
80bded910a verify: fix mq misfire 2011-07-14 12:39:39 -05:00
Matt Mackall
d310d155f9 verify: filter messages about missing null manifests (issue2900) 2011-07-13 16:28:46 -05:00
Matt Mackall
1f03009146 verify: filter messages about missing null manifests (issue2900) 2011-07-13 16:28:46 -05:00
Martin Geisler
6a3d9310ab code style: prefer 'is' and 'is not' tests with singletons 2010-11-22 18:15:58 +01:00
timeless
d78a15767f verify/progress: using gerund to indicate action and adding units 2010-08-02 07:15:47 +03:00
Thomas Arendsen Hein
48cd219ead verify: fix "missing revlog!" errors for revlog format v0 and add test
With revlog format v0 the .d files are empty if the only revision stored is an
empty file. Since Mercurial can no longer create format v0 repositories, but
still use it, add a script which creates a repository with a single empty file.
This can be used in other tests if wanted.
2010-09-05 22:32:11 +02:00
Matt Mackall
7ed158a8ab verify: initialize rp variable in case we hit out of memory 2010-08-05 16:17:33 -05:00
Matt Mackall
aa7e2a7659 verify: reduce memory footprint when unpacking files
By never holding a reference to the unpacked string, we avoid holding two
consecutive large files in memory.
2010-08-05 16:17:17 -05:00
Matt Mackall
6b7d6bea8c verify: report exceptions that don't have a str() method 2010-08-05 16:17:17 -05:00
Steve Borho
b31717c291 verify: improve progress descriptions
For GUIs, the progress bar is disconnected visually from the text that
is output by ui.write(), so it's better to be a little bit redundant in
naming the status.  "checking" is redundant, since the user is running
the verify command.  'changesets', 'manifests', etc, tell the user what
is being checked (the entity being counted in the progress bar.
2010-04-13 23:12:23 -05:00
Martin Geisler
f3b2ed5d56 progress: use a verb (+noun) in present participle 2010-03-15 18:33:39 +01:00
Martin Geisler
e2e1279b27 progress: mark strings for translation 2010-02-17 23:07:50 +01:00
Augie Fackler
458129e75a verify: call ui.progress() 2010-02-10 18:46:19 -06:00
Matt Mackall
8d99be19f0 many, many trivial check-code fixups 2010-01-25 00:05:27 -06:00
Matt Mackall
595d66f424 Update license to GPLv2+ 2010-01-19 22:20:08 -06:00
Sune Foldager
36a958fe4d verify: report existence of journal 2009-11-02 10:15:04 +01:00
Matt Mackall
a777761788 verify: filter the candidate list for broken linkrevs 2009-10-28 13:17:03 -05:00
Patrick Mezard
c463f2299e verify: detect file copy sources not in parents with --verbose 2009-10-06 22:46:31 +02:00
Martin Geisler
ae0794fd45 coding style: use a space after comma
I left a cases like 'lambda x,y:' alone -- the lack of a space does
not bother me as much when the variables are single letters.
2009-07-22 23:12:54 +02:00
Alejandro Santos
bc1b8b3654 verify: fix scope issues with del statement 2009-07-05 11:04:31 +02:00
Matt Mackall
3f99330a0a verify: demote warning about nullid in copy to note 2009-07-01 00:41:14 -05:00
Benoit Boissinot
f23fc93dd5 verify: use set instead of dict 2009-05-17 04:14:15 +02:00
Peter Arrenbrecht
35e8011b63 verify: detect manifest revs not in any changeset 2009-05-14 16:22:49 +02:00
Benoit Boissinot
fdd0aa0449 verify: reference the correct linkrev when a filelog is missing
when a filelog is missing, the first bad revision is the first revision
where the filelog is referenced, not 0.
2009-05-04 19:51:08 +02:00
Henrik Stuart
fbd8e53ee1 verify: avoid exception on missing file revlog
Previously, accessing the filelinkrevs of a specific file that happens to
have already been unlinked from the filesystem, e.g. due to a partial rollback
having occurred, will trigger a KeyError being raised.

Co-contributor: Sune Foldager <cryo@cyanite.org>
2009-04-24 10:44:39 +02:00
Martin Geisler
750183bdad updated license to be explicit about GPL version 2 2009-04-26 01:08:54 +02:00
Matt Mackall
2f9b02c62d replace util.sort with sorted built-in
This is marginally faster for small and moderately-sized lists
2009-04-26 16:50:44 -05:00
Martin Geisler
56c8ce33ee verify: combine sets instead of concatenating lists 2009-04-25 22:26:39 +02:00
Martin Geisler
44aa7e92d1 util: use built-in set instead of util.unique 2009-04-22 00:56:06 +02:00
Ronny Pfannschmidt
5356baa346 switch lock releasing in the core from gc to explicit 2009-04-22 02:01:22 +02:00
Wagner Bruna
b2fafee0f4 verify, i18n: fix unmarked strings 2009-03-29 19:56:53 -03:00
Peter Arrenbrecht
a2d3e23eef cleanup: drop variables for unused return values
They are unnecessary. I did leave them in localrepo.py where there is
something like:

  _junk = foo()
  _junk = None

to free memory early. I don't know if just `foo()` will free the return
value as early.
2009-03-23 13:13:02 +01:00
Benoit Boissinot
c34938cba1 verify: find correct first corrupted cset for missing/corrupted revlogs 2009-03-07 20:16:03 +01:00
Benoit Boissinot
5ed5555a2d verify: do not abort on fully corrupted revlog 2009-03-07 20:04:56 +01:00
Matt Mackall
193584d590 Merge with stable 2009-01-21 14:14:56 -06:00
Matt Mackall
3ff835714e verify: don't trip over binary files starting with 01 0a 2009-01-21 11:15:47 -06:00
Dirkjan Ochtman
574603a8c0 use dict.iteritems() rather than dict.items()
This should be faster and more future-proof. Calls where the result is to be
sorted using util.sort() have been left unchanged. Calls to .items() on
configparser objects have been left as-is, too.
2009-01-12 09:16:03 +01:00
Matt Mackall
b2807810c6 linkrev: take a revision number rather than a hash 2008-11-12 15:19:14 -06:00
John Mulligan
636223becf issue 1144: prevent traceback on verify of bundles 2008-10-18 14:43:14 -04:00
Benoit Boissinot
1343a1f47c d5e923544dd7 uses err() instead of warn() but prototype doesn't match
we might want to make warn() look more like err() in the future
to avoid this kind of problem.
2008-09-08 00:50:34 +02:00
Matt Mackall
2793481364 store: change handling of decoding errors 2008-08-13 20:18:43 -05:00
Adrian Buehlmann
a318975eaf verify: check repo.store 2008-08-13 20:18:41 -05:00
Matt Mackall
e3f5f88298 verify: only warn on copy nullid 2008-08-13 20:18:40 -05:00
Matt Mackall
a65ef7bc5d util: add sort helper 2008-06-27 18:28:45 -05:00
Matt Mackall
26bd918734 verify: lots of refactoring
- simplify finding first bad rev
- no need to count changesets
- add exc function to simplify exception handling
- combine checksize and checkversion to checklog
- unify missing revlog detection in checklog
- add checkentry to consolidate
  - linkrev lookup
  - detailed check of linkrev
  - detailed check of parents
  - duplicate checking
- use checkentry for changelog, manifest, and files
- simplify havecl and havemf
- track all changesets refering to a manifest
- move unnamed file check somewhere more useful
- reorder crosschecks
- fix filenodes crosscheck and add exception handling
- check unpacked size field
2008-06-26 14:35:50 -05:00
Matt Mackall
07f882031a verify: add some local variables 2008-06-26 14:35:50 -05:00
Matt Mackall
bc715be859 add __len__ and __iter__ methods to repo and revlog 2008-06-26 14:35:50 -05:00
Patrick Mezard
e6b5e91a5d verify: check copy source revlog and nodeid 2008-04-14 22:31:33 +02:00
Joel Rosdahl
5dae3059a0 Expand import * to allow Pyflakes to find problems 2008-03-06 22:23:26 +01:00
Matt Mackall
a93c9d4d89 verify: improve handling of empty or missing files
- explicitly notice empty or missing changeset, manifest or file
  revlogs
- shortcircuit warnings relating to missing changeset or manifest
  revlogs
- fix changeset/manifest crosscheck swapped variables
- properly sort crosscheck messages
2007-11-20 15:46:20 -06:00