Patchwork D9523: debugdiscovery: clarify internal key name in debugobsolete

login
register
mail settings
Submitter phabricator
Date Dec. 5, 2020, 2:32 p.m.
Message ID <differential-rev-PHID-DREV-wuatn2ovjp62gg6auua2-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/47806/
State Superseded
Headers show

Comments

phabricator - Dec. 5, 2020, 2:32 p.m.
marmoute created this revision.
marmoute added a comment.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.


  initial sent before test run (refresh post test run imminent)

REVISION SUMMARY
  They were probably clear when they got added initially but with more key around,
  they gain to be clearer.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  mercurial/debugcommands.py

CHANGE DETAILS




To: marmoute, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/mercurial/debugcommands.py b/mercurial/debugcommands.py
--- a/mercurial/debugcommands.py
+++ b/mercurial/debugcommands.py
@@ -1024,13 +1024,13 @@ 
     data = {}
     data[b'elapsed'] = t.elapsed
     data[b'nb-common'] = len(common)
-    data[b'nb-common-local'] = len(common & lheads)
-    data[b'nb-common-remote'] = len(common & rheads)
-    data[b'nb-common-both'] = len(common & rheads & lheads)
-    data[b'nb-local'] = len(lheads)
-    data[b'nb-local-missing'] = data[b'nb-local'] - data[b'nb-common-local']
-    data[b'nb-remote'] = len(rheads)
-    data[b'nb-remote-unknown'] = data[b'nb-remote'] - data[b'nb-common-remote']
+    data[b'nb-common-head-local'] = len(common & lheads)
+    data[b'nb-common-head-remote'] = len(common & rheads)
+    data[b'nb-common-head-both'] = len(common & rheads & lheads)
+    data[b'nb-head-local'] = len(lheads)
+    data[b'nb-head-local-missing'] = data[b'nb-head-local'] - data[b'nb-common-head-local']
+    data[b'nb-head-remote'] = len(rheads)
+    data[b'nb-head-remote-unknown'] = data[b'nb-head-remote'] - data[b'nb-common-head-remote']
     data[b'nb-revs'] = len(repo.revs(b'all()'))
     data[b'nb-revs-common'] = len(repo.revs(b'::%ln', common))
     data[b'nb-revs-missing'] = data[b'nb-revs'] - data[b'nb-revs-common']
@@ -1039,15 +1039,15 @@ 
     ui.writenoi18n(b"elapsed time:  %(elapsed)f seconds\n" % data)
     ui.writenoi18n(b"heads summary:\n")
     ui.writenoi18n(b"  total common heads:  %(nb-common)9d\n" % data)
-    ui.writenoi18n(b"    also local heads:  %(nb-common-local)9d\n" % data)
-    ui.writenoi18n(b"    also remote heads: %(nb-common-remote)9d\n" % data)
-    ui.writenoi18n(b"    both:              %(nb-common-both)9d\n" % data)
-    ui.writenoi18n(b"  local heads:         %(nb-local)9d\n" % data)
-    ui.writenoi18n(b"    common:            %(nb-common-local)9d\n" % data)
-    ui.writenoi18n(b"    missing:           %(nb-local-missing)9d\n" % data)
-    ui.writenoi18n(b"  remote heads:        %(nb-remote)9d\n" % data)
-    ui.writenoi18n(b"    common:            %(nb-common-remote)9d\n" % data)
-    ui.writenoi18n(b"    unknown:           %(nb-remote-unknown)9d\n" % data)
+    ui.writenoi18n(b"    also local heads:  %(nb-common-head-local)9d\n" % data)
+    ui.writenoi18n(b"    also remote heads: %(nb-common-head-remote)9d\n" % data)
+    ui.writenoi18n(b"    both:              %(nb-common-head-both)9d\n" % data)
+    ui.writenoi18n(b"  local heads:         %(nb-head-local)9d\n" % data)
+    ui.writenoi18n(b"    common:            %(nb-common-head-local)9d\n" % data)
+    ui.writenoi18n(b"    missing:           %(nb-head-local-missing)9d\n" % data)
+    ui.writenoi18n(b"  remote heads:        %(nb-head-remote)9d\n" % data)
+    ui.writenoi18n(b"    common:            %(nb-common-head-remote)9d\n" % data)
+    ui.writenoi18n(b"    unknown:           %(nb-head-remote-unknown)9d\n" % data)
     ui.writenoi18n(b"local changesets:      %(nb-revs)9d\n" % data)
     ui.writenoi18n(b"  common:              %(nb-revs-common)9d\n" % data)
     ui.writenoi18n(b"  missing:             %(nb-revs-missing)9d\n" % data)