Automatically remove unnecessary `# noqa` comments
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
tests
.coveragerc
.gitignore
.pre-commit-config.yaml
.pre-commit-hooks.yaml
.travis.yml
LICENSE
README.md
requirements-dev.txt
setup.cfg
setup.py
tox.ini
yesqa.py

README.md

Build Status Coverage Status

yesqa

A tool (and pre-commit hook) to automatically remove unnecessary # noqa comments, for example: a check that's no longer applicable (say you increased your max line length), a mistake (# noqa added to a line that wasn't failing), or other code in the file caused it to no longer need a # noqa (such as an unused import).

Installation

pip install yesqa

As a pre-commit hook

See pre-commit for instructions

Sample .pre-commit-config.yaml:

-   repo: https://github.com/asottile/yesqa
    rev: v0.0.8
    hooks:
    -   id: yesqa

If you need to select a specific version of flake8 and/or run with specific flake8 plugins, add them to additional_dependencies.