[PATCH] dispatch: disable demandimport when invoking the debugger
Jordi Gutiérrez Hermoso
jordigh at octave.org
Thu Sep 10 13:31:31 UTC 2015
# HG changeset patch
# User Jordi Gutiérrez Hermoso <jordigh at octave.org>
# Date 1441891810 14400
# Thu Sep 10 09:30:10 2015 -0400
# Node ID 4db58521c46a1202b058a1a5c1e26d491c108188
# Parent ea489d94e1dc1fc3dc1dcbef1c86c18c49605ed1
dispatch: disable demandimport when invoking the debugger
Turns out that demandimport confuses pudb, which does some pretty
complicated imports. I think it's reasonable to disable demandimport
here.
diff --git a/mercurial/dispatch.py b/mercurial/dispatch.py
--- a/mercurial/dispatch.py
+++ b/mercurial/dispatch.py
@@ -181,8 +181,8 @@ def _runcatch(req):
debugtrace[debugger] == debugtrace['pdb']):
ui.warn(_("%s debugger specified "
"but its module was not found\n") % debugger)
-
- debugtrace[debugger]()
+ with demandimport.disabled():
+ debugtrace[debugger]()
try:
return _dispatch(req)
finally:
More information about the Mercurial-devel
mailing list