Skip to content

python Mega-Linter Flavor

Docker Image Size (tag) Docker Pulls

Description

Optimized for PYTHON based projects

Usage

  • GitHub Action: nvuillam/mega-linter/flavors/python@v4
  • Docker image: nvuillam/mega-linter-python:v4
  • mega-linter-runner: mega-linter-runner --flavor python

Embedded linters

Languages

Language Linter Configuration key Format/Fix
BASH bash-exec BASH_EXEC
shellcheck BASH_SHELLCHECK
shfmt BASH_SHFMT ✔
GROOVY npm-groovy-lint GROOVY_NPM_GROOVY_LINT ✔
KOTLIN ktlint KOTLIN_KTLINT ✔
PYTHON pylint PYTHON_PYLINT
black PYTHON_BLACK ✔
flake8 PYTHON_FLAKE8
isort PYTHON_ISORT ✔
bandit PYTHON_BANDIT
mypy PYTHON_MYPY
SQL sql-lint SQL_SQL_LINT
sqlfluff SQL_SQLFLUFF

Formats

Format Linter Configuration key Format/Fix
CSS stylelint CSS_STYLELINT ✔
scss-lint CSS_SCSS_LINT
ENV dotenv-linter ENV_DOTENV_LINTER ✔
GRAPHQL graphql-schema-linter GRAPHQL_GRAPHQL_SCHEMA_LINTER
HTML htmlhint HTML_HTMLHINT
JSON jsonlint JSON_JSONLINT
eslint-plugin-jsonc JSON_ESLINT_PLUGIN_JSONC ✔
v8r JSON_V8R
prettier JSON_PRETTIER ✔
MARKDOWN markdownlint MARKDOWN_MARKDOWNLINT ✔
remark-lint MARKDOWN_REMARK_LINT ✔
markdown-link-check MARKDOWN_MARKDOWN_LINK_CHECK
markdown-table-formatter MARKDOWN_MARKDOWN_TABLE_FORMATTER ✔
PROTOBUF protolint PROTOBUF_PROTOLINT ✔
RST rst-lint RST_RST_LINT
rstcheck RST_RSTCHECK
rstfmt RST_RSTFMT ✔
XML xmllint XML_XMLLINT
YAML prettier YAML_PRETTIER ✔
yamllint YAML_YAMLLINT
v8r YAML_V8R

Tooling formats

Tooling format Linter Configuration key Format/Fix
ACTION actionlint ACTION_ACTIONLINT
ANSIBLE ansible-lint ANSIBLE_ANSIBLE_LINT
DOCKERFILE dockerfilelint DOCKERFILE_DOCKERFILELINT
hadolint DOCKERFILE_HADOLINT
EDITORCONFIG editorconfig-checker EDITORCONFIG_EDITORCONFIG_CHECKER
KUBERNETES kubeval KUBERNETES_KUBEVAL
OPENAPI spectral OPENAPI_SPECTRAL
SNAKEMAKE snakemake SNAKEMAKE_LINT
snakefmt SNAKEMAKE_SNAKEFMT ✔
TEKTON tekton-lint TEKTON_TEKTON_LINT

Other

Code quality checker Linter Configuration key Format/Fix
COPYPASTE jscpd COPYPASTE_JSCPD
CREDENTIALS secretlint CREDENTIALS_SECRETLINT
GIT git_diff GIT_GIT_DIFF
SPELL misspell SPELL_MISSPELL ✔
cspell SPELL_CSPELL