Skip to main content

flake8 extension for click

Project description

click-linter

Flake8 plugin for detecting click best practices

Checks

  • CLC001: checks for missing help text for click.option-s
  • CLC100: missing argument for click.option
  • CLC101: click option name does not begin with '-'
  • CLC102: click argument name begins with '-'
  • CLC103: click parameter is missing name
  • CLC200: click.launch may be called with user input, leading to a security vulnerability

Installing

$ python -m pip install flake8-click

Specify python2 or python3 to install for a specific Python version.

And double check that it was installed correctly:

$ python -m flake8 -h
Usage: flake8 [options] file file ...

...

Installed plugins: flake8-click : 0.1.0, mccabe: 0.5.3, pycodestyle: 2.2.0, pyflakes: 1.3.0

Note the flake8-click: 0.1.0.

Using

Click best practices is a flake8 plugin. You can easily use this plugin by

$ python -m flake8 --select=CLC /path/to/code

Testing

$ pytest

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

flake8_click-0.2.0-py3-none-any.whl (5.0 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page