# HG changeset patch # User Augie Fackler # Date 2017-04-03 23:03:34 # Node ID d955b02d8ec636dec65ee07879fb2e3f7f71be73 # Parent 81abd0d12c8641df666d356f6033d84cd55977a8 util: fix %-formatting on docstring by moving a closing parenthesis We have to do the % formatting over the sysstr, since the things we're going to splat into it are themselves sysstrs. This is probably technically wrong-ish, since bt is probably actually a bytestr here, but this fixes the immediate issue, which was that hg was broken on Python 3. diff --git a/mercurial/util.py b/mercurial/util.py --- a/mercurial/util.py +++ b/mercurial/util.py @@ -3705,8 +3705,8 @@ def bundlecompressiontopics(): if not bt or not bt[0]: continue - doc = pycompat.sysstr('``%s``\n %s' % ( - bt[0], engine.bundletype.__doc__)) + doc = pycompat.sysstr('``%s``\n %s') % ( + bt[0], engine.bundletype.__doc__) value = docobject() value.__doc__ = doc