D4469: debugcommands: use our CBOR decoder

indygreg (Gregory Szorc) phabricator at mercurial-scm.org
Wed Sep 5 08:23:48 EDT 2018


This revision was automatically updated to reflect the committed changes.
Closed by commit rHGe5eb67dea6e8: debugcommands: use our CBOR decoder (authored by indygreg, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D4469?vs=10766&id=10786

REVISION DETAIL
  https://phab.mercurial-scm.org/D4469

AFFECTED FILES
  mercurial/debugcommands.py

CHANGE DETAILS

diff --git a/mercurial/debugcommands.py b/mercurial/debugcommands.py
--- a/mercurial/debugcommands.py
+++ b/mercurial/debugcommands.py
@@ -32,9 +32,6 @@
     nullrev,
     short,
 )
-from .thirdparty import (
-    cbor,
-)
 from . import (
     bundle2,
     changegroup,
@@ -83,6 +80,7 @@
     wireprotov2peer,
 )
 from .utils import (
+    cborutil,
     dateutil,
     procutil,
     stringutil,
@@ -3321,7 +3319,8 @@
 
             if res.headers.get('Content-Type') == 'application/mercurial-cbor':
                 ui.write(_('cbor> %s\n') %
-                         stringutil.pprint(cbor.loads(body), bprefix=True,
+                         stringutil.pprint(cborutil.decodeall(body)[0],
+                                           bprefix=True,
                                            indent=2))
 
         elif action == 'close':



To: indygreg, #hg-reviewers, pulkit
Cc: mercurial-devel


More information about the Mercurial-devel mailing list