streamclone: update progress later to avoid passing None to util.bytecount
authorAugie Fackler <raf@durin42.com>
Sun, 17 Jun 2018 23:03:23 -0400
changeset 38360 c1fca51c26f3
parent 38359 876352ea831e
child 38361 2ceea1554d1e
streamclone: update progress later to avoid passing None to util.bytecount Differential Revision: https://phab.mercurial-scm.org/D3773
mercurial/streamclone.py
--- a/mercurial/streamclone.py	Sun Jun 17 23:00:08 2018 -0400
+++ b/mercurial/streamclone.py	Sun Jun 17 23:03:23 2018 -0400
@@ -621,10 +621,10 @@
         elapsed = util.timer() - start
         if elapsed <= 0:
             elapsed = 0.001
-        progress.update(None)
         repo.ui.status(_('transferred %s in %.1f seconds (%s/sec)\n') %
                        (util.bytecount(progress.pos), elapsed,
                         util.bytecount(progress.pos / elapsed)))
+        progress.update(None)
 
 def applybundlev2(repo, fp, filecount, filesize, requirements):
     missingreqs = [r for r in requirements if r not in repo.supported]