Skip to content

STYLE: upgrade flake8 #48061

Closed
Closed
@MarcoGorelli

Description

@MarcoGorelli

Issue here is:

  1. checkout the create-pr-action/pre-commit-config-update-0 branch
  2. run pre-commit run flake8 --all-files. You should see some errors like:
pandas/tests/indexes/categorical/test_formats.py:24:89: E501 line too long (98 > 88 characters)
pandas/tests/indexes/categorical/test_formats.py:55:89: E501 line too long (98 > 88 characters)
pandas/tests/indexes/categorical/test_formats.py:89:89: E501 line too long (90 > 88 characters)
pandas/tests/frame/test_query_eval.py:917:17: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/frame/test_query_eval.py:917:26: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/frame/test_query_eval.py:958:17: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/frame/test_query_eval.py:958:26: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/core/strings/object_array.py:375:69: B023 Function definition does not bind loop variable 'pat'.
pandas/tests/window/test_rolling.py:819:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/window/test_rolling.py:867:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/window/test_rolling.py:917:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/window/test_rolling.py:969:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/io/parser/test_c_parser_only.py:194:49: B023 Function definition does not bind loop variable 'actual_val'.
pandas/tests/window/test_expanding.py:221:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/window/test_expanding.py:240:10: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/arrays/categorical/test_repr.py:321:89: E501 line too long (97 > 88 characters)
pandas/tests/arrays/categorical/test_repr.py:354:89: E501 line too long (97 > 88 characters)
pandas/io/formats/excel.py:175:6: B019 Use of `functools.lru_cache` or `functools.cache` on methods can lead to memory leaks. The cache may retain instance references, preventing garbage collection.
pandas/tests/arrays/masked/test_arithmetic.py:58:9: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/arrays/masked/test_arithmetic.py:217:9: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/groupby/transform/test_transform.py:760:9: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/indexes/multi/test_formats.py:186:89: E501 line too long (95 > 88 characters)
scripts/no_bool_in_generic.py:42:21: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/tests/io/sas/test_sas7bdat.py:323:17: B020 Found for loop that reassigns the iterable it is iterating with each iterable value.
pandas/io/pytables.py:4131:38: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4[132](https://github.com/pandas-dev/pandas/runs/7809209712?check_suite_focus=true#step:4:134):39: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4133:39: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4144:38: B023 Function definition does not bind loop variable 'op'.
pandas/io/pytables.py:4145:36: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4151:59: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4155:43: B023 Function definition does not bind loop variable 'obj'.
pandas/io/pytables.py:4157:38: B023 Function definition does not bind loop variable 'op'.
pandas/io/pytables.py:4158:36: B023 Function definition does not bind loop variable 'obj'.
  1. Fixup these errors, and when pre-commit run flake8 --all-files passes, stage, commit, and push!

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions