# HG changeset patch
# User Phil Cohen <phillco@fb.com>
# Date 2017-05-04 01:26:57
# Node ID c939fdce0fde77d4b1b03ba3402ee68f104be448
# Parent  448ed4d3ee9095c4f41d3b26b0a773569d5d57f8

demandimport: add urwid.command_map to ignore list

The useful pudb debugger can be used with Mercurial, but its import of urwid
fails when demandimport is enabled. Add urwid.command_map to the ignore list so
pudb can be used with hg without disabling all of demandimport.

diff --git a/mercurial/demandimport.py b/mercurial/demandimport.py
--- a/mercurial/demandimport.py
+++ b/mercurial/demandimport.py
@@ -297,6 +297,7 @@ ignore = [
     'distutils.msvc9compiler',
     '__builtin__',
     'builtins',
+    'urwid.command_map', # for pudb
     ]
 
 if _pypy:
diff --git a/tests/test-check-code.t b/tests/test-check-code.t
--- a/tests/test-check-code.t
+++ b/tests/test-check-code.t
@@ -13,7 +13,7 @@ New errors are not allowed. Warnings are
    >             r.revision(r.node(x))
    don't convert rev to node before passing to revision(nodeorrev)
   Skipping i18n/polib.py it has no-che?k-code (glob)
-  mercurial/demandimport.py:313:
+  mercurial/demandimport.py:314:
    >     if os.environ.get('HGDEMANDIMPORT') != 'disable':
    use encoding.environ instead (py3)
   mercurial/encoding.py:54: