changeset 30937:b35e05103641

dispatch: load debugcommand before extension Multiple extension will manipulate commands on load, we need the debug command to be loaded before that point.
author Pierre-Yves David <pierre-yves.david@ens-lyon.org>
date Mon, 13 Feb 2017 16:35:49 +0100
parents 455677a7667f
children fec3dbaa7f83
files mercurial/dispatch.py
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/dispatch.py	Mon Feb 13 09:44:16 2017 -0800
+++ b/mercurial/dispatch.py	Mon Feb 13 16:35:49 2017 +0100
@@ -655,6 +655,10 @@
     rpath = _earlygetopt(["-R", "--repository", "--repo"], args)
     path, lui = _getlocal(ui, rpath)
 
+    # Side-effect of accessing is debugcommands module is guaranteed to be
+    # imported and commands.table is populated.
+    debugcommands.command
+
     # Configure extensions in phases: uisetup, extsetup, cmdtable, and
     # reposetup. Programs like TortoiseHg will call _dispatch several
     # times so we keep track of configured extensions in _loaded.
@@ -674,10 +678,6 @@
 
     # (reposetup is handled in hg.repository)
 
-    # Side-effect of accessing is debugcommands module is guaranteed to be
-    # imported and commands.table is populated.
-    debugcommands.command
-
     addaliases(lui, commands.table)
 
     # All aliases and commands are completely defined, now.