sapling/edenscm/hgext
Zeyi Fan 6aa90444ab fix used before assignment error
Summary:
I'm getting reports on Eden failed to import data from Mercurial. One of the error message I have seen is `local variable 'rcvd' referenced before assignment` (unfortunately we don't have the backtrace to locate the exact problem), and this is the only place in our codebase has a variable named `rcvd`.

The log contains this error: P62827869$210-217

So if there is any exception raised in `self._connect`, `rcvd` and `total` will not be initialized, and these variables are being used to log the error message in the `except` block:

diffusion/FBS/browse/master/fbcode/scm/hg/edenscm/hgext/remotefilelog/fileserverclient.py;18aa2052b752f1255dd53474d541c4a4177bfef5$732-737

Reviewed By: quark-zju

Differential Revision: D15069162

fbshipit-source-id: 16ec56820107fbbb24d426ce309b38a88d7eae5b
2019-04-25 10:25:44 -07:00
..
absorb mutation: add absorb support 2019-04-11 02:45:16 -07:00
amend commands: update help text for amend 2019-04-19 11:16:56 -07:00
commitcloud visibility: support cloud sync 2019-04-11 07:49:20 -07:00
convert subrepo: remove subrepo support 2019-03-11 10:43:55 -07:00
extlib blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
fastannotate hgext: reformat using black 2019-03-13 18:35:09 -07:00
fastmanifest manifest: drop manifestv2 support 2019-03-26 13:32:45 -07:00
fsmonitor blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
hgevents codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
hggit hggit: stop git-updatemeta walk when we finish commits with extras 2019-03-20 14:33:58 -07:00
hgsubversion codeformat - remove weird looking + for string concat on the same line 2019-03-13 11:40:26 -07:00
highlight codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
infinitepush infinitepush: fix the help text for scratch bookmark commands 2019-04-16 13:47:36 -07:00
lfs hg: fix lfs and journal extension postshare wrapping 2019-02-07 18:58:40 -08:00
memcommit memcommit: enforce target parent to be original parent 2019-03-13 11:50:42 -07:00
p4fastimport codeformat - remove weird looking + for string concat on the same line 2019-03-13 11:40:26 -07:00
perfsuite metrics: slightly change the API 2019-03-20 22:49:18 -07:00
pushrebase pushrebase: throw if prechangegroup fails 2019-04-22 17:10:15 -07:00
remotefilelog fix used before assignment error 2019-04-25 10:25:44 -07:00
repogenerator codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
treemanifest remotefilelog: avoid double close of mutable packs 2019-04-22 10:15:42 -07:00
__init__.py codemod: move Python packages to edenscm 2019-01-28 18:35:41 -08:00
arcdiff.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
automv.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
blackbox.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
catnotate.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
checkmessagehook.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
chistedit.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
churn.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
cleanobsstore.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
clienttelemetry.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
clindex.pyx blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
clonebundles.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
commitextras.py test-revset: do not use "hg branch" directly 2019-02-14 17:44:39 -08:00
conflictinfo.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
copytrace.py copytrace: fix an issue where undesirable entries are reported 2019-02-25 12:43:20 -08:00
crdump.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
debugcommitmessage.py subrepo: remove subrepo support 2019-03-11 10:43:55 -07:00
debugshell.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
dialect.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
directaccess.py branchmap: drop revbranchcache and other unused logic 2019-02-22 21:02:41 -08:00
dirsync.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
disablesymlinks.py disablesymlinks: add extension to disable symlinks 2019-02-06 08:41:34 -08:00
drop.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
edrecord.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
eol.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
errorredirect.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
extdiff.py subrepo: remove subrepo support 2019-03-11 10:43:55 -07:00
extorder.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
extutil.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
fastlog.py fastlog: patch follow revset instead 2019-04-16 22:19:19 -07:00
fbconduit.py fbconduit: fix resolving phabricator callsign for WWW 2019-03-13 18:35:09 -07:00
fbhistedit.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
fixcorrupt.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
generic_bisect.py codemod: move Python packages to edenscm 2019-01-28 18:35:41 -08:00
githelp.py codeformat - remove weird looking + for string concat on the same line 2019-03-13 11:40:26 -07:00
gitlookup.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
gitrevset.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
globalrevs.py globalrevs: fail quickly for invalid searches during globalrev fast lookup 2019-04-02 11:23:19 -07:00
gpg.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
grepdiff.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
grpcheck.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
hgsql.py hgsql: use fetchall method in committodb 2019-04-13 03:20:27 -07:00
hiddenerror.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
histedit.py histedit: fix call to hex in loginfo 2019-04-12 01:57:56 -07:00
infinitepushbackup.py infinitepushbackup: exclude hidden commits from backup heads 2019-04-11 02:45:15 -07:00
interactiveui.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
journal.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
linkrevcache.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
logginghelper.py logginghelper: log normalized repo name 2019-03-04 00:05:00 -08:00
lz4revlog.py rust: move bindings to a single python extension 2019-02-01 17:53:22 -08:00
mergedriver.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
morecolors.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
morestatus.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
myparent.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
nointerrupt.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
ownercheck.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
patchrmdir.pyx codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
phabdiff.py Safer parsing of referenced tasknumber 2019-04-24 19:25:11 -07:00
phabstatus.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
phrevset.py phrevset: avoid crashing on null graphql reply 2019-04-09 07:53:43 -07:00
progressfile.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
pullcreatemarkers.py visibility: pullcreatemarkers should exclude hidden commits 2019-04-11 07:49:21 -07:00
purge.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
rage.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
rebase.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
remotenames.py remotenames: make push with tracking bookmark work with infinitepush 2019-04-17 08:41:12 -07:00
reset.py visibility: update visibility when commits are modified 2019-03-08 03:05:58 -08:00
sampling.py sampling: silence BaseException.message deprecation warning 2019-04-22 17:58:07 -07:00
schemes.py hgext: reformat using black 2019-03-13 18:35:09 -07:00
sendunbundlereplay.py mononoke: preserve more output from hg side in the sync job 2019-04-10 18:05:37 -07:00
share.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
shelve.py shelve: add shelvename template keyword 2019-04-15 05:44:49 -07:00
sigtrace.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
simplecache.py simplecache: add checksum to simplecache values 2019-02-20 13:56:33 -08:00
smartlog.py smartlog: move ancestor calcuation to smartlog revset 2019-03-21 17:33:45 -07:00
sparse.py blackbox: clean up blackbox logging and log more during rage 2019-04-23 02:48:50 -07:00
sshaskpass.py sshaskpass: workaround sys.executable 2019-02-26 18:19:43 -08:00
stablerev.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
stat.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
traceprof.pyx codemod: move Python packages to edenscm 2019-01-28 18:35:41 -08:00
tweakdefaults.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
undo.py visibility: add undo support 2019-03-27 04:49:14 -07:00
whereami.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
win32mbcs.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00
win32text.py codemod: import from the edenscm package 2019-01-29 17:25:32 -08:00