# HG changeset patch # User Anton Shestakov # Date 1615711721 -28800 # Node ID 64082dc8888ab3536b3da0bffc0111cfbdb20af1 # Parent a86c2682f6086ba2adb8ce04e97bc2c554554fe7 evolve: use correct unit for cache building progress Also make it translatable, while we're at it. diff -r a86c2682f608 -r 64082dc8888a hgext3rd/evolve/depthcache.py --- a/hgext3rd/evolve/depthcache.py Fri Mar 12 11:05:20 2021 +0100 +++ b/hgext3rd/evolve/depthcache.py Sun Mar 14 16:48:41 2021 +0800 @@ -117,7 +117,7 @@ def progress(pos, rev=None): revstr = b'' if rev is None else (b'rev %d' % rev) compat.progress(repo.ui, b'updating depth cache', - pos, revstr, unit=b'revision', total=total) + pos, revstr, unit=_(b'changesets'), total=total) progress(0) for idx, rev in enumerate(data, 1): assert rev == len(self._data), (rev, len(self._data)) diff -r a86c2682f608 -r 64082dc8888a hgext3rd/evolve/firstmergecache.py --- a/hgext3rd/evolve/firstmergecache.py Fri Mar 12 11:05:20 2021 +0100 +++ b/hgext3rd/evolve/firstmergecache.py Sun Mar 14 16:48:41 2021 +0800 @@ -11,6 +11,7 @@ import array +from mercurial.i18n import _ from mercurial import ( localrepo, node as nodemod, @@ -79,7 +80,7 @@ def progress(pos, rev=None): revstr = b'' if rev is None else (b'rev %d' % rev) compat.progress(repo.ui, b'updating firstmerge cache', - pos, revstr, unit=b'revision', total=total) + pos, revstr, unit=_(b'changesets'), total=total) progress(0) for idx, rev in enumerate(data, 1): assert rev == len(self._data), (rev, len(self._data)) diff -r a86c2682f608 -r 64082dc8888a hgext3rd/evolve/obsdiscovery.py --- a/hgext3rd/evolve/obsdiscovery.py Fri Mar 12 11:05:20 2021 +0100 +++ b/hgext3rd/evolve/obsdiscovery.py Sun Mar 14 16:48:41 2021 +0800 @@ -472,7 +472,7 @@ def progress(pos, rev=None): revstr = b'' if rev is None else (b'rev %d' % rev) compat.progress(repo.ui, b'updating obshashrange cache', - pos, revstr, unit=b'revision', total=total) + pos, revstr, unit=_(b'changesets'), total=total) # warm the cache for the new revs progress(0) for idx, r in enumerate(revs): diff -r a86c2682f608 -r 64082dc8888a hgext3rd/evolve/stablesort.py --- a/hgext3rd/evolve/stablesort.py Fri Mar 12 11:05:20 2021 +0100 +++ b/hgext3rd/evolve/stablesort.py Sun Mar 14 16:48:41 2021 +0800 @@ -864,7 +864,7 @@ def progress(pos, rev=None): revstr = b'' if rev is None else (b'rev %d' % rev) compat.progress(repo.ui, b'updating stablesort cache', - pos, revstr, unit=b'revision', total=total) + pos, revstr, unit=_(b'changesets'), total=total) progress(0) for idx, rev in enumerate(data):