diff --git a/pandas/tests/io/test_html.py b/pandas/tests/io/test_html.py index 9263bc142e585..0ea1203359153 100644 --- a/pandas/tests/io/test_html.py +++ b/pandas/tests/io/test_html.py @@ -1280,9 +1280,14 @@ def seek(self, offset): def seekable(self): return True + # GH 49036 pylint checks for presence of __next__ for iterators + def __next__(self): + ... + def __iter__(self) -> Iterator: - # to fool `is_file_like`, should never end up here - assert False + # `is_file_like` depends on the presence of + # the __iter__ attribute. + return self good = MockFile("
spam
eggs
") bad = MockFile("
spameggs
") diff --git a/pyproject.toml b/pyproject.toml index 2232a00a9aa89..00467a5dfe206 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,6 @@ disable = [ "no-method-argument", "no-name-in-module", "no-value-for-parameter", - "non-iterator-returned", "not-an-iterable", "not-callable", "redundant-keyword-arg",