Page MenuHomePhabricator

[lint] bump flake8 to >5
ClosedPublic

Authored by PiRK on Apr 10 2023, 08:08.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC1add51d5cb83: [lint] bump flake8 to >5
Summary

Flake8 5.x has a --require-plugins option that could be useful using some of the many flake8 plugins, such as flake8-comprehensions or flake8-simplify..
Without this option, we could already use the plugins, but we cannot enforce their usage. Users would not be warned if they run arc lint without the required plugin installed.

Bumping the flake8 version raises two E275 missing whitespace after keyword errors, because assert is incorrectly used like a function rather than like a keyword.

Note that 6.0.0 is the latest version available, but it requires python>=3.8.1, so I didn't use >6 in .arclint because we still support python 3.6. Debian Bullseye has python 3.9, so 6.0.0 is fine for that distro. I checked that both flake8 5.0.4 and 6.0.0 produce the same results for our codebase.

Test Plan
arc lint --everything

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable