Skip to main content
Join the official Python Developers Survey 2018 and win valuable prizes: Start the survey!

Output Checkstyle XML reports of flake8 violations.

Project description

https://circleci.com/gh/d9magai/flake8-checkstyle/tree/master.svg?style=svg

flake8-checkstyle

Output Checkstyle XML reports of flake8 violations.

Quick Start

$ pip install flake8-checkstyle

To print a Checkstyle report, use the --format=checkstyle command line argument.

$ flake8 --format=checkstyle path/to/code

The output will look like this:

<?xml version='1.0' encoding='utf-8'?>
<checkstyle>
  <file name="example.py">
    <error column="1" line="3" message="H306: imports not in alphabetical order (sys, os)" severity="info" source="hacking"/>
    <error column="1" line="3" message="I100 Import statements are in the wrong order. import os should be before import sys" severity="info" source="flake8-import-order"/>
    <error column="27" line="4" message="F821 undefined name 'index'" severity="info" source="pyflakes"/>
    <error column="1" line="7" message="E302 expected 2 blank lines, found 1" severity="error" source="pycodestyle"/>
    <error column="1" line="7" message="D101 Missing docstring in public class" severity="info" source="flake8-docstrings"/>
    <error column="20" line="7" message="W291 trailing whitespace" severity="warning" source="pycodestyle"/>
  </file>
</checkstyle>

Checkstyle rule

flake8-checkstyle can coexist with other flake8 plugins. The prefix code determines source and severity.

prefix code source severity
E pycodestyle error
W pycodestyle warning
F pyflakes info
C mccabe info
H hacking info
I flake8-import-order info
D flake8-docstrings info

License

  • MIT License

History

0.1.2 (2018-05-07)

  • Support for flake8 –output-file argument

0.1.1 (2018-01-15)

  • Modify release settings

0.1.0 (2018-01-15)

  • Fixed some flake8 violations
  • Introduced CircleCI
  • Add status badge
  • Release settings

0.0.1 (2018-01-08)

  • First release on PyPI.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Filename, size & hash SHA256 hash help File type Python version Upload date
flake8-checkstyle-0.1.2.tar.gz (4.9 kB) Copy SHA256 hash SHA256 Source None May 7, 2018

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page