# HG changeset patch # User Yuya Nishihara # Date 2014-09-17 13:34:34 # Node ID 0a714a1f7d5c0d754e4c566a4372e391144854f8 # Parent b9f7f3eeb99c206897beacc0eb323ab9c178e599 formatter: convert None to json null It will be used by "annotate" command to represent the workingctx revision. diff --git a/mercurial/formatter.py b/mercurial/formatter.py --- a/mercurial/formatter.py +++ b/mercurial/formatter.py @@ -98,6 +98,8 @@ class pickleformatter(baseformatter): def _jsonifyobj(v): if isinstance(v, tuple): return '[' + ', '.join(_jsonifyobj(e) for e in v) + ']' + elif v is None: + return 'null' elif v is True: return 'true' elif v is False: