summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPierre Sassoulas <pierre.sassoulas@gmail.com>2021-12-27 14:42:47 +0100
committerGitHub <noreply@github.com>2021-12-27 14:42:47 +0100
commit9bf30ddf7d3046410c19ce510d5258b57cb9caed (patch)
tree8c233adceb090c2357eefd3ee41c89c8109bd516
parent81237097e8451b840ce837e0c53710f4fa81c8b9 (diff)
downloadpylint-git-add-typing-to-checker-registration.tar.gz
Apply suggestions from code reviewadd-typing-to-checker-registration
Co-authored-by: Marc Mueller <30130371+cdce8p@users.noreply.github.com>
-rw-r--r--pylint/checkers/similar.py1
-rw-r--r--pylint/checkers/typecheck.py1
-rw-r--r--pylint/extensions/code_style.py1
3 files changed, 3 insertions, 0 deletions
diff --git a/pylint/checkers/similar.py b/pylint/checkers/similar.py
index 112cd4bbb..51ec27c0b 100644
--- a/pylint/checkers/similar.py
+++ b/pylint/checkers/similar.py
@@ -78,6 +78,7 @@ from pylint.utils import LinterStats, decoding_stream
if TYPE_CHECKING:
from pylint.lint import PyLinter
+
DEFAULT_MIN_SIMILARITY_LINE = 4
REGEX_FOR_LINES_WITH_CONTENT = re.compile(r".*\w+")
diff --git a/pylint/checkers/typecheck.py b/pylint/checkers/typecheck.py
index be4fa61be..a2239469a 100644
--- a/pylint/checkers/typecheck.py
+++ b/pylint/checkers/typecheck.py
@@ -112,6 +112,7 @@ from pylint.utils import get_global_option
if TYPE_CHECKING:
from pylint.lint import PyLinter
+
CallableObjects = Union[
bases.BoundMethod,
bases.UnboundMethod,
diff --git a/pylint/extensions/code_style.py b/pylint/extensions/code_style.py
index e3149bb8d..7082c991c 100644
--- a/pylint/extensions/code_style.py
+++ b/pylint/extensions/code_style.py
@@ -10,6 +10,7 @@ from pylint.utils.utils import get_global_option
if TYPE_CHECKING:
from pylint.lint import PyLinter
+
if sys.version_info >= (3, 10):
from typing import TypeGuard
else: