D7270: linelog: suppress annoying pytype warning about an ignored metaclass
durin42 (Augie Fackler)
phabricator at mercurial-scm.org
Wed Nov 6 22:57:29 UTC 2019
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
This isn't actively hurting us right now, and it's not trivial to set
up this metaclass correctly on both Python 2 and Python 3 without
dragging in all of `six`, but we still get lots of typechecking
goodness with this error suppressed.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D7270
AFFECTED FILES
mercurial/linelog.py
CHANGE DETAILS
diff --git a/mercurial/linelog.py b/mercurial/linelog.py
--- a/mercurial/linelog.py
+++ b/mercurial/linelog.py
@@ -53,7 +53,7 @@
return iter(self.lines)
-class _llinstruction(object):
+class _llinstruction(object): # pytype: disable=ignored-metaclass
__metaclass__ = abc.ABCMeta
To: durin42, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list