Skip to content

Instantly share code, notes, and snippets.

@jquast
Created November 14, 2014 21:55
Show Gist options
  • Save jquast/30a5296e7c4439fc374a to your computer and use it in GitHub Desktop.
Save jquast/30a5296e7c4439fc374a to your computer and use it in GitHub Desktop.
inherits:
- strictness_veryhigh
ignore:
- (^|/)\..+
- ^docs/
- ^roots/.*/files/
test-warnings: true
output-format: grouped
dodgy:
# Looks at Python code to search for things which look "dodgy"
# such as passwords or git conflict artifacts
run: true
frosted:
# static analysis
run: true
# note, adding '__salt__' as an additional-builtins
# as like pylint is done by an *Environment Variable*,
# see tox.ini
mccabe:
# complexity checking.
#
# unfortunately 4 offenders already exist in
# roots/_{modules,states}/*.py
run: false
pep257:
# docstring checking
run: false
pep8:
# style checking
run: true
options:
max-line-length: 100
pyflakes:
# preferring 'frosted' instead (a fork of)
run: false
pylint:
# static analysis and then some
run: true
options:
max-line-length: 100
additional-builtins:
# from https://github.com/saltstack/salt/blob/develop/.pylintrc
# NOTE: duplicated as PYFLAKES_BUILTINS for pyflakes in tox.ini
- __salt__
- __opts__
- __opts__
- __salt__
- __pillar__
- __grains__
- __context__
- __ret__
- __env__
- __low__
- __states__
- __lowstate__
- __running__
- __active_provider_name__
- __master_opts__
# allow 'log' as global constant
const-rgx: "(([A-Z_][A-Z0-9_]*)|(__.*__)|log)$"
const-hint: "(([A-Z_][A-Z0-9_]*)|(__.*__)|log)$"
# pytest module has dynamiclly assigned functions,
# raising errors such as: E1101: Module 'pytest' has
# no 'mark' member
ignored-classes: pytest
disable:
# Too many lines in module
- C0302
# Used * or ** magic
- W0142
# Used builtin function 'filter'.
# (For maintainability, one should prefer list comprehension.)
- W0141
pyroma:
# we don't use any
run: false
vulture:
# this tool does a good job of finding unused code.
#
# Unfortunately, much of our code (roots/_modules/keystoke.py, for example)
# is made available only from command line using 'salt'.
run: false
# vim: noai:ts=4:sw=4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment