flakeheaven.formatters._grouped

class flakeheaven.formatters._grouped.GroupedFormatter(options: argparse.Namespace)[source]

Bases: flakeheaven.formatters._colored.ColoredFormatter

Copied and modified formatter from wemake-python-styleguide. It’s named not wemake to avoid conflicts with original formatter.

Initialize with the options parsed from config and cli.

This also calls a hook, after_init(), so subclasses do not need to call super to call this method.

Parameters

options (argparse.Namespace) – User specified configuration parsed from both configuration files and the command-line interface.

_print_header(filename: str) None[source]
after_init()[source]

Check for a custom format string.

format(error: flake8.style_guide.Violation) str[source]

Called to format each individual flake8.style_guide.Violation.

handle(error: flake8.style_guide.Violation) None[source]

Processes each flake8.style_guide.Violation to print it and all related.

output_fd: Optional[IO[str]]
show_statistics(statistics: flake8.statistics.Statistics) None[source]

Called when --statistic option is passed.

flakeheaven.formatters._grouped._count_per_filename(statistics: flake8.statistics.Statistics, error_code: str) DefaultDict[str, int][source]