Skip to main content

FlakeHeaven

License: MIT python versions

version conda Downloads

CI Docs

FlakeHeaven is a Flake8 wrapper to make it cool.

This project is a fork of FlakeHell. FlakeHell and other forks of it such as flakehell/flakehell are no longer maintained and do not work with Flake8 4.0.x.

FlakeHeaven works with Flake8 4.0.1 or greater. This fork will be maintained by the community that developed the existing forks.

output example

Compatibility

FlakeHeaven supports all flake8 plugins, formatters, and configs. However, FlakeHeaven has it's own beautiful way to configure enabled plugins and codes. So, options like --ignore and --select unsupported. You can have flake8 and FlakeHeaven in one project if you want but enabled plugins should be explicitly specified.

Installation

python3 -m pip install --user flakeheaven

Usage

First of all, let's create pyproject.toml config:

[tool.flakeheaven]
# optionally inherit from remote config (or local if you want)
base = "https://raw.githubusercontent.com/flakeheaven/flakeheaven/main/pyproject.toml"
# specify any flake8 options. For example, exclude "example.py":
exclude = ["example.py"]
# make output nice
format = "grouped"
# 80 chars aren't enough in 21 century
max_line_length = 90
# show line of source code in output
show_source = true

# list of plugins and rules for them
[tool.flakeheaven.plugins]
# include everything in pyflakes except F401
pyflakes = ["+*", "-F401"]
# enable only codes from S100 to S199
flake8-bandit = ["-*", "+S1??"]
# enable everything that starts from `flake8-`
"flake8-*" = ["+*"]
# explicitly disable plugin
flake8-docstrings = ["-*"]

Show plugins that aren't installed yet:

flakeheaven missed

Show installed plugins, used plugins, specified rules, codes prefixes:

flakeheaven plugins

plugins command output

Show codes and messages for a specific plugin:

flakeheaven codes pyflakes

codes command output

Run flake8 against the code:

flakeheaven lint

This command accepts all the same arguments as Flake8.

Read the documentation for more information.

Contributing

  1. Add tests when possible (eg for features / fixes / refactor, etc. )
  2. add your contribution to the code / docs
  3. Ensure your code passes all (both oririnal and your own) tests.
  4. commit using proper header
  5. create a PR

Contributions are welcome! A few ideas where you can contribute:

  • Improve documentation.
  • Add more tests.
  • Improve performance.
  • Found a bug? Fix it!
  • Made an article about FlakeHeaven? Great! Let's add it into the README.md.
  • Don't have time to code? No worries! Just tell your friends and subscribers about the project. More users -> more contributors -> more cool features.

A convenient way to run tests is using Poetry:

curl -sSL https://install.python-poetry.org | python3 -
poetry install
poetry run pytest tests

Thank you ❤️

The FlakeHeaven mascot (Flaky) is created by @illustrator.way and licensed under the CC BY-SA 4.0 license.

Metadata

Release files for flakeheaven 3.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flakeheaven 3.2.0
File Size Uploaded Provenance Actions
flakeheaven-3.2.0.tar.gz 34.3 kB Without provenance Details for flakeheaven-3.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for flakeheaven 3.2.0
File Interpreter ABI Platform Actions
flakeheaven-3.2.0-py3-none-any.whl Python 3 none any Details for flakeheaven-3.2.0-py3-none-any.whl

Total release size: 80.6 kB

Release files / flakeheaven-3.2.0.tar.gz

Download URL flakeheaven-3.2.0.tar.gz
Size 34.3 kB
Tags Source
SHA-256 checksum
How to use checksums
225333d7bf309079f19a2c5f02d427fc7558a0d0c065944de88041ca94f5525c
BLAKE2b-256 checksum
How to use checksums
4723fd1a98682898f40ca6ac276ccbd228f5f68eb4d13f37a96471772152fbcb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.2 CPython/3.8.14 Linux/5.15.0-1022-azure

Release files / flakeheaven-3.2.0-py3-none-any.whl

Download URL flakeheaven-3.2.0-py3-none-any.whl
Size 46.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ec5a508c3db64d73128b65cb2a5a2c0a2d9f2e4b435e9fa2bcc03bf0df86da79
BLAKE2b-256 checksum
How to use checksums
b9abefab520cab101a4072ec4e0d1c50a180aa06028b9d7159feb2a83a6eed69
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.2.2 CPython/3.8.14 Linux/5.15.0-1022-azure

Security for flakeheaven 3.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page