sapling/hgext3rd
Adam Simpkins 642dea7e2c fixcorrupt: automatically look back as far as necessary
Summary:
Update the fixcorrupt extension to look back as far as necessary in the revlog
to find a good entry.  Previously the user had to supply a good value using the
--checklen argument.  If --checklen was too small, fixcorrupt could end up
trying to truncate in the middle of a corrupted section of the revlog, which
would cause problems as it was still using corrupted data.

This change ensures that fixcorrupt always looks back far enough to find a good
entry.  We start by looking at the last 10 entries, and double that amount each
time the first item in the list is still bad.

Test Plan:
Used it to fix a corrupted fbsource repository where the corruption was 36
commits back.

Reviewers: #mercurial, quark, stash

Reviewed By: stash

Subscribers: stash, net-systems-diffs@fb.com, yogeshwer, mjpieters

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

Signature: t1:4874243:1492007518:7406b03a9967815a496a8c2fae394c5f21f7e60a
2017-04-12 14:09:22 -07:00
..
absorb absorb: move to a package 2017-04-03 10:40:31 -07:00
lfs lfs: add a fast path for filelog.size 2017-04-11 13:20:58 -07:00
__init__.py debian: Do not package hgext3rd/__init__.py 2016-12-19 16:34:49 -08:00
allowunstable.py codemod: get rid of ui.backupconfig 2017-03-17 19:42:50 -07:00
arcdiff.py arcdiff: use absolute paths 2017-01-20 00:24:45 -08:00
backups.py codemod: replace repo.join to repo.vfs.join 2017-03-13 20:51:37 -07:00
bundle2hooks.py hgext: move single file extensions to hgext3rd 2016-07-08 13:15:42 +01:00
catnotate.py testedwith: change testedwith to "ships-with-fb-hgext" 2016-11-29 13:24:07 +00:00
checkmessagehook.py checkmessagehook: use reposetup to setup a hook 2017-03-02 01:05:19 -08:00
chistedit.py fb-hgext: fix test-check-code.t failures 2017-03-24 15:22:31 -07:00
cleanobsstore.py hgext3rd: cleanobsstore extension 2017-04-12 01:16:01 -07:00
commitextras.py testedwith: change testedwith to "ships-with-fb-hgext" 2016-11-29 13:24:07 +00:00
debugcommitmessage.py extension to print commit message that would be supplied to editor 2016-10-03 04:39:51 -07:00
debuginhibit.py debuginhibit: remove warning if inhibit is not enabled 2017-02-25 15:28:15 -08:00
dialect.py testedwith: change testedwith to "ships-with-fb-hgext" 2016-11-29 13:24:07 +00:00
dirsync.py dirsync: rename in-repo config file to .hgdirsync 2017-03-20 10:55:43 -07:00
edrecord.py edrecord: allow specifying a different editor for chunk selection 2017-04-06 16:49:27 -07:00
errorredirect.py errorredirect: log and fallback to old error handler when appropriate 2017-04-04 10:27:30 -07:00
extorder.py fb-hgext: fix test-check-code.t failures 2017-03-24 15:22:31 -07:00
extutil.py extutil: add unit tests for runbgcommand 2017-04-11 11:25:40 -07:00
fastlog.py fastlog: fix ScmQuery request parameter name 2017-04-12 13:51:18 -07:00
fastpartialmatch.py fastpartialmatch: catch write exceptions 2017-04-07 02:21:54 -07:00
fbamend.py codemod: get rid of ui.backupconfig 2017-03-17 19:42:50 -07:00
fbconduit.py fbconduit: fix error handling in gitnode() revset 2017-02-15 12:35:06 -08:00
fbhistedit.py codemod: replace repo.join to repo.vfs.join 2017-03-13 20:51:37 -07:00
fbmetaedit.py fbmetaedit: intoduce the extension 2017-03-15 07:40:26 -07:00
fbshow.py hgext: rename show.py to fbshow.py to prevent upstream collision 2017-04-06 13:36:18 -07:00
fixcorrupt.py fixcorrupt: automatically look back as far as necessary 2017-04-12 14:09:22 -07:00
generic_bisect.py fastpartialmatch: use bisect to quickly find matching revisions 2017-02-02 05:12:10 -08:00
githelp.py hgext: githelp support for commit -C 2016-12-02 10:41:54 +00:00
gitlookup.py gitlookup: fix lookup if not string is passed 2017-04-04 01:04:40 -07:00
gitrevset.py gitlookup: fix gitnode() template and revset 2017-03-29 07:13:41 -07:00
grepdiff.py grepdiff: fix to match upstream 2017-03-12 12:49:18 -07:00
grpcheck.py testedwith: change testedwith to "ships-with-fb-hgext" 2016-11-29 13:24:07 +00:00
hiddenerror.py hiddenerror: fix out of bounds error 2017-02-25 15:26:19 -08:00
inhibitwarn.py pyflakes: fix all pyflakes issues 2016-11-25 00:23:21 +00:00
linkrevcache.py linkrevcache: update documentation 2016-12-02 00:59:48 +00:00
logginghelper.py fb-hgext: fix test-check-code.t failures 2017-03-24 15:22:31 -07:00
mergedriver.py codemod: get rid of ui.backupconfig 2017-03-17 19:42:50 -07:00
morestatus.py fb-hgext: fix test-check-code.t failures 2017-03-24 15:22:31 -07:00
myparent.py templates: fix help messages for template keywords 2017-01-19 12:52:54 -08:00
nointerrupt.py hgext: move single file extensions to hgext3rd 2016-07-08 13:15:42 +01:00
ownercheck.py ownercheck: new extension to prevent operations on repos not owned 2016-07-26 13:10:15 +01:00
patchpython.py patchpython: fix test-check tests 2016-10-20 16:03:31 +01:00
patchrmdir.pyx patchrmdir: new extension to workaround rmdir kernel issues 2017-03-15 18:55:48 -07:00
perftweaks.py perftweaks: remove hardlink tweak 2017-03-27 10:43:01 -07:00
phabdiff.py templates: fix help messages for template keywords 2017-01-19 12:52:54 -08:00
phabstatus.py phabstatus: fail gracefully if necessary arcrc settings are missing 2017-03-30 11:55:39 -07:00
phrevset.py pyflakes: fix all pyflakes issues 2016-11-25 00:23:21 +00:00
pullcreatemarkers.py pyflakes: fix all pyflakes issues 2016-11-25 00:23:21 +00:00
pushrebase.py pushrebase: send obsmarkers to client if client supports it 2017-04-11 13:21:27 -07:00
pushvars.py pyflakes: fix all pyflakes issues 2016-11-25 00:23:21 +00:00
rage.py rage: fix hg sparse entry in hg rage output 2017-04-11 07:19:26 -07:00
reset.py codemod: replace repo.join to repo.vfs.join 2017-03-13 20:51:37 -07:00
sampling.py sampling: fix comment 2017-02-07 00:39:26 -08:00
sigtrace.py sigtrace: new extension provides stack traces on signal 2017-03-07 17:25:40 -08:00
simplecache.py testedwith: change testedwith to "ships-with-fb-hgext" 2016-11-29 13:24:07 +00:00
smartlog.py codemod: get rid of ui.backupconfig 2017-03-17 19:42:50 -07:00
sparse.py sparse: update hg.updaterepo wrapper to match upstream 2017-03-07 10:27:05 -08:00
sshaskpass.py sshaskpass: do not import mercurial 2017-01-05 17:04:34 +00:00
tweakdefaults.py tweakdefaults: fix common incorrect PAGER config automatically 2017-04-10 17:38:22 -07:00
uncommit.py uncommit: don't lose copy information of remaining files (issue5403) 2017-02-01 02:17:40 -08:00
upgradegeneraldelta.py pyflakes: fix all pyflakes issues 2016-11-25 00:23:21 +00:00
whereami.py whereami: add extension 2017-02-17 16:01:02 +00:00