diff options
-rw-r--r-- | astroid/as_string.py | 2 | ||||
-rw-r--r-- | astroid/helpers.py | 2 | ||||
-rw-r--r-- | astroid/protocols.py | 1 | ||||
-rw-r--r-- | astroid/scoped_nodes.py | 4 | ||||
-rw-r--r-- | astroid/tests/unittest_inference.py | 1 | ||||
-rw-r--r-- | astroid/tests/unittest_lookup.py | 2 |
6 files changed, 3 insertions, 9 deletions
diff --git a/astroid/as_string.py b/astroid/as_string.py index b58b5e62..3cd6e0d2 100644 --- a/astroid/as_string.py +++ b/astroid/as_string.py @@ -21,8 +21,6 @@ * :func:`dump` function return an internal representation of nodes found in the tree, useful for debugging or understanding the tree structure """ -import sys - # pylint: disable=unused-argument diff --git a/astroid/helpers.py b/astroid/helpers.py index 69d6efea..942b0a02 100644 --- a/astroid/helpers.py +++ b/astroid/helpers.py @@ -197,7 +197,7 @@ def _type_check(type1, type2): def is_subtype(type1, type2): """Check if *type1* is a subtype of *type2*.""" - return _type_check(type2, type1) + return _type_check(type1=type2, type2=type1) def is_supertype(type1, type2): diff --git a/astroid/protocols.py b/astroid/protocols.py index 310e5cd3..c1825f1d 100644 --- a/astroid/protocols.py +++ b/astroid/protocols.py @@ -22,7 +22,6 @@ where it makes sense. import collections import operator as operator_mod -import sys import itertools diff --git a/astroid/scoped_nodes.py b/astroid/scoped_nodes.py index f7c35bf4..d02b6534 100644 --- a/astroid/scoped_nodes.py +++ b/astroid/scoped_nodes.py @@ -1755,8 +1755,8 @@ def _is_metaclass(klass, seen=None): baseobj_name = baseobj.qname() if baseobj_name in seen: continue - else: - seen.add(baseobj_name) + + seen.add(baseobj_name) if isinstance(baseobj, bases.Instance): # not abstract return False diff --git a/astroid/tests/unittest_inference.py b/astroid/tests/unittest_inference.py index cdca231d..f047e692 100644 --- a/astroid/tests/unittest_inference.py +++ b/astroid/tests/unittest_inference.py @@ -24,7 +24,6 @@ """ # pylint: disable=too-many-lines import platform -import sys from functools import partial import unittest from unittest.mock import patch diff --git a/astroid/tests/unittest_lookup.py b/astroid/tests/unittest_lookup.py index ebc8453d..f293cc98 100644 --- a/astroid/tests/unittest_lookup.py +++ b/astroid/tests/unittest_lookup.py @@ -10,14 +10,12 @@ """tests for the astroid variable lookup capabilities """ import functools -import sys import unittest from astroid import builder from astroid import exceptions from astroid import nodes from astroid import scoped_nodes -from astroid import util from astroid.tests import resources |