| 1 |
# Based on Apache 2.0 licensed code from https://github.com/ClusterHQ/flocker |
| 2 |
|
| 3 |
[MASTER] |
| 4 |
|
| 5 |
# Specify a configuration file. |
| 6 |
#rcfile= |
| 7 |
|
| 8 |
# Python code to execute, usually for sys.path manipulation such as |
| 9 |
# pygtk.require(). |
| 10 |
#init-hook= |
| 11 |
|
| 12 |
# Add files or directories to the blacklist. They should be base names, not |
| 13 |
# paths. |
| 14 |
ignore=old_mbar.py,_version.py |
| 15 |
|
| 16 |
# Pickle collected data for later comparisons. |
| 17 |
persistent=no |
| 18 |
|
| 19 |
# List of plugins (as comma separated values of python modules names) to load, |
| 20 |
# usually to register additional checkers. |
| 21 |
load-plugins= |
| 22 |
|
| 23 |
# Use multiple processes to speed up Pylint. |
| 24 |
# DO NOT CHANGE THIS VALUES >1 HIDE RESULTS!!!!! |
| 25 |
jobs=1 |
| 26 |
|
| 27 |
# Allow loading of arbitrary C extensions. Extensions are imported into the |
| 28 |
# active Python interpreter and may run arbitrary code. |
| 29 |
unsafe-load-any-extension=no |
| 30 |
|
| 31 |
# A comma-separated list of package or module names from where C extensions may |
| 32 |
# be loaded. Extensions are loading into the active Python interpreter and may |
| 33 |
# run arbitrary code |
| 34 |
extension-pkg-whitelist= |
| 35 |
|
| 36 |
# Allow optimization of some AST trees. This will activate a peephole AST |
| 37 |
# optimizer, which will apply various small optimizations. For instance, it can |
| 38 |
# be used to obtain the result of joining multiple strings with the addition |
| 39 |
# operator. Joining a lot of strings can lead to a maximum recursion error in |
| 40 |
# Pylint and this flag can prevent that. It has one side effect, the resulting |
| 41 |
# AST will be different than the one from reality. |
| 42 |
optimize-ast=no |
| 43 |
|
| 44 |
|
| 45 |
[MESSAGES CONTROL] |
| 46 |
|
| 47 |
# Only show warnings with the listed confidence levels. Leave empty to show |
| 48 |
# all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED |
| 49 |
confidence= |
| 50 |
|
| 51 |
# Enable the message, report, category or checker with the given id(s). You can |
| 52 |
# either give multiple identifier separated by comma (,) or put this option |
| 53 |
# multiple time. See also the "--disable" option for examples. |
| 54 |
disable=all |
| 55 |
|
| 56 |
enable=import-error, |
| 57 |
import-self, |
| 58 |
reimported, |
| 59 |
wildcard-import, |
| 60 |
misplaced-future, |
| 61 |
deprecated-module, |
| 62 |
unpacking-non-sequence, |
| 63 |
invalid-all-object, |
| 64 |
undefined-all-variable, |
| 65 |
used-before-assignment, |
| 66 |
cell-var-from-loop, |
| 67 |
global-variable-undefined, |
| 68 |
redefine-in-handler, |
| 69 |
unused-import, |
| 70 |
unused-wildcard-import, |
| 71 |
global-variable-not-assigned, |
| 72 |
undefined-loop-variable, |
| 73 |
global-statement, |
| 74 |
global-at-module-level, |
| 75 |
bad-open-mode, |
| 76 |
redundant-unittest-assert, |
| 77 |
boolean-datetime |
| 78 |
deprecated-method, |
| 79 |
anomalous-unicode-escape-in-string, |
| 80 |
anomalous-backslash-in-string, |
| 81 |
not-in-loop, |
| 82 |
continue-in-finally, |
| 83 |
abstract-class-instantiated, |
| 84 |
star-needs-assignment-target, |
| 85 |
duplicate-argument-name, |
| 86 |
return-in-init, |
| 87 |
too-many-star-expressions, |
| 88 |
nonlocal-and-global, |
| 89 |
return-outside-function, |
| 90 |
return-arg-in-generator, |
| 91 |
invalid-star-assignment-target, |
| 92 |
bad-reversed-sequence, |
| 93 |
nonexistent-operator, |
| 94 |
yield-outside-function, |
| 95 |
init-is-generator, |
| 96 |
nonlocal-without-binding, |
| 97 |
lost-exception, |
| 98 |
assert-on-tuple, |
| 99 |
dangerous-default-value, |
| 100 |
duplicate-key, |
| 101 |
useless-else-on-loop |
| 102 |
expression-not-assigned, |
| 103 |
confusing-with-statement, |
| 104 |
unnecessary-lambda, |
| 105 |
pointless-statement, |
| 106 |
pointless-string-statement, |
| 107 |
unnecessary-pass, |
| 108 |
unreachable, |
| 109 |
eval-used, |
| 110 |
exec-used, |
| 111 |
using-constant-test, |
| 112 |
bad-super-call, |
| 113 |
missing-super-argument, |
| 114 |
slots-on-old-class, |
| 115 |
super-on-old-class, |
| 116 |
property-on-old-class, |
| 117 |
not-an-iterable, |
| 118 |
not-a-mapping, |
| 119 |
format-needs-mapping, |
| 120 |
truncated-format-string, |
| 121 |
missing-format-string-key, |
| 122 |
mixed-format-string, |
| 123 |
too-few-format-args, |
| 124 |
bad-str-strip-call, |
| 125 |
too-many-format-args, |
| 126 |
bad-format-character, |
| 127 |
format-combined-specification, |
| 128 |
bad-format-string-key, |
| 129 |
bad-format-string, |
| 130 |
missing-format-attribute, |
| 131 |
missing-format-argument-key, |
| 132 |
unused-format-string-argument |
| 133 |
unused-format-string-key, |
| 134 |
invalid-format-index, |
| 135 |
bad-indentation, |
| 136 |
mixed-indentation, |
| 137 |
unnecessary-semicolon, |
| 138 |
lowercase-l-suffix, |
| 139 |
invalid-encoded-data, |
| 140 |
unpacking-in-except, |
| 141 |
import-star-module-level, |
| 142 |
long-suffix, |
| 143 |
old-octal-literal, |
| 144 |
old-ne-operator, |
| 145 |
backtick, |
| 146 |
old-raise-syntax, |
| 147 |
metaclass-assignment, |
| 148 |
next-method-called, |
| 149 |
dict-iter-method, |
| 150 |
dict-view-method, |
| 151 |
indexing-exception, |
| 152 |
raising-string, |
| 153 |
using-cmp-argument, |
| 154 |
cmp-method, |
| 155 |
coerce-method, |
| 156 |
delslice-method, |
| 157 |
getslice-method, |
| 158 |
hex-method, |
| 159 |
nonzero-method, |
| 160 |
t-method, |
| 161 |
setslice-method, |
| 162 |
logging-format-truncated, |
| 163 |
logging-too-few-args, |
| 164 |
logging-too-many-args, |
| 165 |
logging-unsupported-format, |
| 166 |
logging-format-interpolation, |
| 167 |
invalid-unary-operand-type, |
| 168 |
unsupported-binary-operation, |
| 169 |
not-callable, |
| 170 |
redundant-keyword-arg, |
| 171 |
assignment-from-no-return, |
| 172 |
assignment-from-none, |
| 173 |
not-context-manager, |
| 174 |
repeated-keyword, |
| 175 |
missing-kwoa, |
| 176 |
no-value-for-parameter, |
| 177 |
invalid-sequence-index, |
| 178 |
invalid-slice-index, |
| 179 |
unexpected-keyword-arg, |
| 180 |
unsupported-membership-test, |
| 181 |
unsubscriptable-object, |
| 182 |
access-member-before-definition, |
| 183 |
method-hidden, |
| 184 |
assigning-non-slot, |
| 185 |
duplicate-bases, |
| 186 |
inconsistent-mro, |
| 187 |
inherit-non-class, |
| 188 |
invalid-slots, |
| 189 |
invalid-slots-object, |
| 190 |
no-method-argument, |
| 191 |
no-self-argument, |
| 192 |
unexpected-special-method-signature, |
| 193 |
non-iterator-returned, |
| 194 |
arguments-differ, |
| 195 |
signature-differs, |
| 196 |
bad-staticmethod-argument, |
| 197 |
non-parent-init-called, |
| 198 |
bad-except-order, |
| 199 |
catching-non-exception, |
| 200 |
bad-exception-context, |
| 201 |
notimplemented-raised, |
| 202 |
raising-bad-type, |
| 203 |
raising-non-exception, |
| 204 |
misplaced-bare-raise, |
| 205 |
duplicate-except, |
| 206 |
broad-except, |
| 207 |
nonstandard-exception, |
| 208 |
binary-op-exception, |
| 209 |
bare-except, |
| 210 |
not-async-context-manager, |
| 211 |
yield-inside-async-function |
| 212 |
|
| 213 |
# Needs investigation: |
| 214 |
# abstract-method (might be indicating a bug? probably not though) |
| 215 |
# protected-access (requires some refactoring) |
| 216 |
# attribute-defined-outside-init (requires some refactoring) |
| 217 |
# super-init-not-called (requires some cleanup) |
| 218 |
|
| 219 |
# Things we'd like to enable someday: |
| 220 |
# redefined-builtin (requires a bunch of work to clean up our code first) |
| 221 |
# redefined-outer-name (requires a bunch of work to clean up our code first) |
| 222 |
# undefined-variable (re-enable when pylint fixes https://github.com/PyCQA/pylint/issues/760) |
| 223 |
# no-name-in-module (giving us spurious warnings https://github.com/PyCQA/pylint/issues/73) |
| 224 |
# unused-argument (need to clean up or code a lot, e.g. prefix unused_?) |
| 225 |
# function-redefined (@overload causes lots of spurious warnings) |
| 226 |
# too-many-function-args (@overload causes spurious warnings... I think) |
| 227 |
# parameter-unpacking (needed for eventual Python 3 compat) |
| 228 |
# print-statement (needed for eventual Python 3 compat) |
| 229 |
# filter-builtin-not-iterating (Python 3) |
| 230 |
# map-builtin-not-iterating (Python 3) |
| 231 |
# range-builtin-not-iterating (Python 3) |
| 232 |
# zip-builtin-not-iterating (Python 3) |
| 233 |
# many others relevant to Python 3 |
| 234 |
# unused-variable (a little work to cleanup, is all) |
| 235 |
|
| 236 |
# ... |
| 237 |
[REPORTS] |
| 238 |
|
| 239 |
# Set the output format. Available formats are text, parseable, colorized, msvs |
| 240 |
# (visual studio) and html. You can also give a reporter class, eg |
| 241 |
# mypackage.mymodule.MyReporterClass. |
| 242 |
output-format=parseable |
| 243 |
|
| 244 |
# Put messages in a separate file for each module / package specified on the |
| 245 |
# command line instead of printing them on stdout. Reports (if any) will be |
| 246 |
# written in a file name "pylint_global.[txt|html]". |
| 247 |
files-output=no |
| 248 |
|
| 249 |
# Tells whether to display a full report or only the messages |
| 250 |
reports=no |
| 251 |
|
| 252 |
# Python expression which should return a note less than 10 (10 is the highest |
| 253 |
# note). You have access to the variables errors warning, statement which |
| 254 |
# respectively contain the number of errors / warnings messages and the total |
| 255 |
# number of statements analyzed. This is used by the global evaluation report |
| 256 |
# (RP0004). |
| 257 |
evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10) |
| 258 |
|
| 259 |
# Template used to display messages. This is a python new-style format string |
| 260 |
# used to format the message information. See doc for all details |
| 261 |
#msg-template= |
| 262 |
|
| 263 |
|
| 264 |
[LOGGING] |
| 265 |
|
| 266 |
# Logging modules to check that the string format arguments are in logging |
| 267 |
# function parameter format |
| 268 |
logging-modules=logging |
| 269 |
|
| 270 |
|
| 271 |
[FORMAT] |
| 272 |
|
| 273 |
# Maximum number of characters on a single line. |
| 274 |
max-line-length=100 |
| 275 |
|
| 276 |
# Regexp for a line that is allowed to be longer than the limit. |
| 277 |
ignore-long-lines=^\s*(# )?<?https?://\S+>?$ |
| 278 |
|
| 279 |
# Allow the body of an if to be on the same line as the test if there is no |
| 280 |
# else. |
| 281 |
single-line-if-stmt=no |
| 282 |
|
| 283 |
# List of optional constructs for which whitespace checking is disabled. `dict- |
| 284 |
# separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}. |
| 285 |
# `trailing-comma` allows a space between comma and closing bracket: (a, ). |
| 286 |
# `empty-line` allows space-only lines. |
| 287 |
no-space-check=trailing-comma,dict-separator |
| 288 |
|
| 289 |
# Maximum number of lines in a module |
| 290 |
max-module-lines=1000 |
| 291 |
|
| 292 |
# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1 |
| 293 |
# tab). |
| 294 |
indent-string=' ' |
| 295 |
|
| 296 |
# Number of spaces of indent required inside a hanging or continued line. |
| 297 |
indent-after-paren=4 |
| 298 |
|
| 299 |
# Expected format of line ending, e.g. empty (any line ending), LF or CRLF. |
| 300 |
expected-line-ending-format= |
| 301 |
|
| 302 |
|
| 303 |
[TYPECHECK] |
| 304 |
|
| 305 |
# Tells whether missing members accessed in mixin class should be ignored. A |
| 306 |
# mixin class is detected if its name ends with "mixin" (case insensitive). |
| 307 |
ignore-mixin-members=yes |
| 308 |
|
| 309 |
# List of module names for which member attributes should not be checked |
| 310 |
# (useful for modules/projects where namespaces are manipulated during runtime |
| 311 |
# and thus existing member attributes cannot be deduced by static analysis. It |
| 312 |
# supports qualified module names, as well as Unix pattern matching. |
| 313 |
ignored-modules= |
| 314 |
|
| 315 |
# List of classes names for which member attributes should not be checked |
| 316 |
# (useful for classes with attributes dynamically set). This supports can work |
| 317 |
# with qualified names. |
| 318 |
ignored-classes= |
| 319 |
|
| 320 |
# List of members which are set dynamically and missed by pylint inference |
| 321 |
# system, and so shouldn't trigger E1101 when accessed. Python regular |
| 322 |
# expressions are accepted. |
| 323 |
generated-members= |
| 324 |
|
| 325 |
|
| 326 |
[VARIABLES] |
| 327 |
|
| 328 |
# Tells whether we should check for unused import in __init__ files. |
| 329 |
init-import=no |
| 330 |
|
| 331 |
# A regular expression matching the name of dummy variables (i.e. expectedly |
| 332 |
# not used). |
| 333 |
dummy-variables-rgx=_$|dummy |
| 334 |
|
| 335 |
# List of additional names supposed to be defined in builtins. Remember that |
| 336 |
# you should avoid to define new builtins when possible. |
| 337 |
additional-builtins= |
| 338 |
|
| 339 |
# List of strings which can identify a callback function by name. A callback |
| 340 |
# name must start or end with one of those strings. |
| 341 |
callbacks=cb_,_cb |
| 342 |
|
| 343 |
|
| 344 |
[SIMILARITIES] |
| 345 |
|
| 346 |
# Minimum lines number of a similarity. |
| 347 |
min-similarity-lines=4 |
| 348 |
|
| 349 |
# Ignore comments when computing similarities. |
| 350 |
ignore-comments=yes |
| 351 |
|
| 352 |
# Ignore docstrings when computing similarities. |
| 353 |
ignore-docstrings=yes |
| 354 |
|
| 355 |
# Ignore imports when computing similarities. |
| 356 |
ignore-imports=no |
| 357 |
|
| 358 |
|
| 359 |
[SPELLING] |
| 360 |
|
| 361 |
# Spelling dictionary name. Available dictionaries: none. To make it working |
| 362 |
# install python-enchant package. |
| 363 |
spelling-dict= |
| 364 |
|
| 365 |
# List of comma separated words that should not be checked. |
| 366 |
spelling-ignore-words= |
| 367 |
|
| 368 |
# A path to a file that contains private dictionary; one word per line. |
| 369 |
spelling-private-dict-file= |
| 370 |
|
| 371 |
# Tells whether to store unknown words to indicated private dictionary in |
| 372 |
# --spelling-private-dict-file option instead of raising a message. |
| 373 |
spelling-store-unknown-words=no |
| 374 |
|
| 375 |
|
| 376 |
[MISCELLANEOUS] |
| 377 |
|
| 378 |
# List of note tags to take in consideration, separated by a comma. |
| 379 |
notes=FIXME,XXX,TODO |
| 380 |
|
| 381 |
|
| 382 |
[BASIC] |
| 383 |
|
| 384 |
# List of builtins function names that should not be used, separated by a comma |
| 385 |
bad-functions=map,filter,input |
| 386 |
|
| 387 |
# Good variable names which should always be accepted, separated by a comma |
| 388 |
good-names=i,j,k,ex,Run,_ |
| 389 |
|
| 390 |
# Bad variable names which should always be refused, separated by a comma |
| 391 |
bad-names=foo,bar,baz,toto,tutu,tata |
| 392 |
|
| 393 |
# Colon-delimited sets of names that determine each other's naming style when |
| 394 |
# the name regexes allow several styles. |
| 395 |
name-group= |
| 396 |
|
| 397 |
# Include a hint for the correct naming format with invalid-name |
| 398 |
include-naming-hint=no |
| 399 |
|
| 400 |
# Regular expression matching correct function names |
| 401 |
function-rgx=[a-z_][a-z0-9_]{2,30}$ |
| 402 |
|
| 403 |
# Naming hint for function names |
| 404 |
function-name-hint=[a-z_][a-z0-9_]{2,30}$ |
| 405 |
|
| 406 |
# Regular expression matching correct variable names |
| 407 |
variable-rgx=[a-z_][a-z0-9_]{2,30}$ |
| 408 |
|
| 409 |
# Naming hint for variable names |
| 410 |
variable-name-hint=[a-z_][a-z0-9_]{2,30}$ |
| 411 |
|
| 412 |
# Regular expression matching correct constant names |
| 413 |
const-rgx=(([A-Z_][A-Z0-9_]*)|(__.*__))$ |
| 414 |
|
| 415 |
# Naming hint for constant names |
| 416 |
const-name-hint=(([A-Z_][A-Z0-9_]*)|(__.*__))$ |
| 417 |
|
| 418 |
# Regular expression matching correct attribute names |
| 419 |
attr-rgx=[a-z_][a-z0-9_]{2,30}$ |
| 420 |
|
| 421 |
# Naming hint for attribute names |
| 422 |
attr-name-hint=[a-z_][a-z0-9_]{2,30}$ |
| 423 |
|
| 424 |
# Regular expression matching correct argument names |
| 425 |
argument-rgx=[a-z_][a-z0-9_]{2,30}$ |
| 426 |
|
| 427 |
# Naming hint for argument names |
| 428 |
argument-name-hint=[a-z_][a-z0-9_]{2,30}$ |
| 429 |
|
| 430 |
# Regular expression matching correct class attribute names |
| 431 |
class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$ |
| 432 |
|
| 433 |
# Naming hint for class attribute names |
| 434 |
class-attribute-name-hint=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$ |
| 435 |
|
| 436 |
# Regular expression matching correct inline iteration names |
| 437 |
inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$ |
| 438 |
|
| 439 |
# Naming hint for inline iteration names |
| 440 |
inlinevar-name-hint=[A-Za-z_][A-Za-z0-9_]*$ |
| 441 |
|
| 442 |
# Regular expression matching correct class names |
| 443 |
class-rgx=[A-Z_][a-zA-Z0-9]+$ |
| 444 |
|
| 445 |
# Naming hint for class names |
| 446 |
class-name-hint=[A-Z_][a-zA-Z0-9]+$ |
| 447 |
|
| 448 |
# Regular expression matching correct module names |
| 449 |
module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$ |
| 450 |
|
| 451 |
# Naming hint for module names |
| 452 |
module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$ |
| 453 |
|
| 454 |
# Regular expression matching correct method names |
| 455 |
method-rgx=[a-z_][a-z0-9_]{2,30}$ |
| 456 |
|
| 457 |
# Naming hint for method names |
| 458 |
method-name-hint=[a-z_][a-z0-9_]{2,30}$ |
| 459 |
|
| 460 |
# Regular expression which should only match function or class names that do |
| 461 |
# not require a docstring. |
| 462 |
no-docstring-rgx=^_ |
| 463 |
|
| 464 |
# Minimum line length for functions/classes that require docstrings, shorter |
| 465 |
# ones are exempt. |
| 466 |
docstring-min-length=-1 |
| 467 |
|
| 468 |
|
| 469 |
[ELIF] |
| 470 |
|
| 471 |
# Maximum number of nested blocks for function / method body |
| 472 |
max-nested-blocks=5 |
| 473 |
|
| 474 |
|
| 475 |
[IMPORTS] |
| 476 |
|
| 477 |
# Deprecated modules which should not be used, separated by a comma |
| 478 |
deprecated-modules=regsub,TERMIOS,Bastion,rexec |
| 479 |
|
| 480 |
# Create a graph of every (i.e. internal and external) dependencies in the |
| 481 |
# given file (report RP0402 must not be disabled) |
| 482 |
import-graph= |
| 483 |
|
| 484 |
# Create a graph of external dependencies in the given file (report RP0402 must |
| 485 |
# not be disabled) |
| 486 |
ext-import-graph= |
| 487 |
|
| 488 |
# Create a graph of internal dependencies in the given file (report RP0402 must |
| 489 |
# not be disabled) |
| 490 |
int-import-graph= |
| 491 |
|
| 492 |
|
| 493 |
[DESIGN] |
| 494 |
|
| 495 |
# Maximum number of arguments for function / method |
| 496 |
max-args=5 |
| 497 |
|
| 498 |
# Argument names that match this expression will be ignored. Default to name |
| 499 |
# with leading underscore |
| 500 |
ignored-argument-names=_.* |
| 501 |
|
| 502 |
# Maximum number of locals for function / method body |
| 503 |
max-locals=15 |
| 504 |
|
| 505 |
# Maximum number of return / yield for function / method body |
| 506 |
max-returns=6 |
| 507 |
|
| 508 |
# Maximum number of branch for function / method body |
| 509 |
max-branches=12 |
| 510 |
|
| 511 |
# Maximum number of statements in function / method body |
| 512 |
max-statements=50 |
| 513 |
|
| 514 |
# Maximum number of parents for a class (see R0901). |
| 515 |
max-parents=7 |
| 516 |
|
| 517 |
# Maximum number of attributes for a class (see R0902). |
| 518 |
max-attributes=7 |
| 519 |
|
| 520 |
# Minimum number of public methods for a class (see R0903). |
| 521 |
min-public-methods=2 |
| 522 |
|
| 523 |
# Maximum number of public methods for a class (see R0904). |
| 524 |
max-public-methods=20 |
| 525 |
|
| 526 |
# Maximum number of boolean expressions in a if statement |
| 527 |
max-bool-expr=5 |
| 528 |
|
| 529 |
|
| 530 |
[CLASSES] |
| 531 |
|
| 532 |
# List of method names used to declare (i.e. assign) instance attributes. |
| 533 |
defining-attr-methods=__init__,__new__,setUp |
| 534 |
|
| 535 |
# List of valid names for the first argument in a class method. |
| 536 |
valid-classmethod-first-arg=cls |
| 537 |
|
| 538 |
# List of valid names for the first argument in a metaclass class method. |
| 539 |
valid-metaclass-classmethod-first-arg=mcs |
| 540 |
|
| 541 |
# List of member names, which should be excluded from the protected access |
| 542 |
# warning. |
| 543 |
exclude-protected=_asdict,_fields,_replace,_source,_make |
| 544 |
|
| 545 |
|
| 546 |
[EXCEPTIONS] |
| 547 |
|
| 548 |
# Exceptions that will emit a warning when being caught. Defaults to |
| 549 |
# "Exception" |
| 550 |
overgeneral-exceptions=builtins.Exception |