sapling/fastannotate
Jun Wu b4efcc56cf fastannotate: deal with corrupted files gracefully
Summary:
Previously, fastannotate's annotatecontext would delete individual cache
files (linelog and revmap) if it meets Exception. While the "fastannotate"
command has some retry logic, "debugbuildannotatecache" doesn't, which means
users have to run "debugbuildannotatecache" O(number-of-corrupted-files)
times to unblock. And "fastannotate" does not handle AssertionError which
could be seen as "linelog is corrupted" nicely - it crashes without retry.

Addressing all the above issues by replacing the "assert" to
"CorruptedFileError", catching them and retry properly.

Test Plan: Added a new test.

Reviewers: #sourcecontrol, rmcelroy

Reviewed By: rmcelroy

Subscribers: mjpieters

Differential Revision: https://phabricator.intern.facebook.com/D4233433

Signature: t1:4233433:1480330548:618e80762af2209784ad72ad0658f649b050a080
2016-11-25 19:49:13 +00:00
..
__init__.py fastannotate: add a debug command to update cache 2016-11-01 15:10:21 +00:00
commands.py fastannotate: deal with corrupted files gracefully 2016-11-25 19:49:13 +00:00
context.py fastannotate: deal with corrupted files gracefully 2016-11-25 19:49:13 +00:00
error.py fastannotate: move exception classes to error.py 2016-09-08 14:47:49 +01:00
formatter.py fastannotate: support -r wdir() 2016-10-21 20:50:37 +01:00
hgwebsupport.py fastannotate: fix imports and pyflakes check 2016-10-19 16:05:22 +01:00
protocol.py fastannotate: support remotefilelog 2016-11-03 20:55:16 +00:00
revmap.py fastannotate: add a method to quickly get the last node of the revmap 2016-10-29 19:19:18 +01:00