summaryrefslogtreecommitdiff
path: root/pylint/checkers/refactoring/refactoring_checker.py
diff options
context:
space:
mode:
authorTushar Sadhwani <86737547+tushar-deepsource@users.noreply.github.com>2022-11-14 20:59:46 +0530
committerGitHub <noreply@github.com>2022-11-14 16:29:46 +0100
commit6de674ced02985a2fa23a8e46c11a5328ea117be (patch)
treeb9d345fdceb1a5b61a9c2cedceb9cc9483460741 /pylint/checkers/refactoring/refactoring_checker.py
parentfdd8f1892799c6e8c4aa070d3031c215a77bd1f1 (diff)
downloadpylint-git-6de674ced02985a2fa23a8e46c11a5328ea117be.tar.gz
Suppress `stop-iteration-return` on `itertools.cycle` (#7766)
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
Diffstat (limited to 'pylint/checkers/refactoring/refactoring_checker.py')
-rw-r--r--pylint/checkers/refactoring/refactoring_checker.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pylint/checkers/refactoring/refactoring_checker.py b/pylint/checkers/refactoring/refactoring_checker.py
index 412c8c438..40144c995 100644
--- a/pylint/checkers/refactoring/refactoring_checker.py
+++ b/pylint/checkers/refactoring/refactoring_checker.py
@@ -35,7 +35,7 @@ NodesWithNestedBlocks = Union[
nodes.TryExcept, nodes.TryFinally, nodes.While, nodes.For, nodes.If
]
-KNOWN_INFINITE_ITERATORS = {"itertools.count"}
+KNOWN_INFINITE_ITERATORS = {"itertools.count", "itertools.cycle"}
BUILTIN_EXIT_FUNCS = frozenset(("quit", "exit"))
CALLS_THAT_COULD_BE_REPLACED_BY_WITH = frozenset(
(