# HG changeset patch
# User Yuya Nishihara <y...@tcha.org>
# Date 1523169129 -32400
#      Sun Apr 08 15:32:09 2018 +0900
# Node ID 7ed301f165390dfd2a9f4e8c6f6bc49ecba04c79
# Parent  d08cb276664c86807fc497b0c7b3980d3752b613
py3: do not try to byte-stringify None in cmdutil.tryimportone()

It's a debug message, so just use '' instead.

diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py
--- a/mercurial/cmdutil.py
+++ b/mercurial/cmdutil.py
@@ -1398,7 +1398,7 @@ def tryimportone(ui, repo, hunk, parents
         else:
             # launch the editor
             message = None
-        ui.debug('message:\n%s\n' % message)
+        ui.debug('message:\n%s\n' % (message or ''))
 
         if len(parents) == 1:
             parents.append(repo[nullid])
_______________________________________________
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

Reply via email to