D7408: extensions: hide two confusing import statements from pytype

durin42 (Augie Fackler) phabricator at mercurial-scm.org
Thu Nov 14 21:12:07 UTC 2019


durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REPOSITORY
  rHG Mercurial

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

AFFECTED FILES
  mercurial/extensions.py

CHANGE DETAILS

diff --git a/mercurial/extensions.py b/mercurial/extensions.py
--- a/mercurial/extensions.py
+++ b/mercurial/extensions.py
@@ -781,7 +781,7 @@
 def disabled():
     '''find disabled extensions from hgext. returns a dict of {name: desc}'''
     try:
-        from hgext import __index__
+        from hgext import __index__  # pytype: disable=import-error
 
         return dict(
             (name, gettext(desc))
@@ -807,7 +807,7 @@
 def disabledext(name):
     '''find a specific disabled extension from hgext. returns desc'''
     try:
-        from hgext import __index__
+        from hgext import __index__  # pytype: disable=import-error
 
         if name in _order:  # enabled
             return



To: durin42, #hg-reviewers
Cc: mercurial-devel


More information about the Mercurial-devel mailing list