flakeheaven.formatters._stat

class flakeheaven.formatters._stat.StatFormatter(options: argparse.Namespace)[source]

Bases: flakeheaven.formatters._colored.ColoredFormatter

Show count of every code occurance

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.

_codes: DefaultDict[str, DefaultDict[str, int]]
_msgs: DefaultDict[str, Dict[str, str]]
after_init() None[source]

Check for a custom format string.

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

Format and write error out.

If an output filename is specified, write formatted errors to that file. Otherwise, print the formatted error to standard out.

stop() None[source]

Clean up after reporting is finished.