Update flake8 for new tool support and more reliable output parsing.
Review Request #11558 — Created March 27, 2021 and submitted
Flake8Toolto subclass the newer
BaseTool, and to
use the newer features it offers (dependencies, improved centralized
base command building, and standardized error code/column output).
The reporting actually parses the CodeClimate format. Flake8 supports
plugins for reporters, and one of them,
CodeClimate output. This is a format that many other tools support, so
it makes sense to use it wherever possible. A new utility function has
been added to convert these payloads into comments.
We unconditionally depend on
flake8-jsonfor the CodeClimate support,
flake8itself isn't installed. This is a small dependency, and
ensures we don't need to worry about having users install yet one more
Unit tests pass on Python 2.7 and 3.x.