blob: 3f676ce3e3808d3c62b08bf4eeb60e8b44b1c927 [file] [log] [blame]
Dennis Dmitrieve56c8b92017-06-16 01:53:16 +03001[MASTER]
2
3# Specify a configuration file.
4#rcfile=
5
6# Python code to execute, usually for sys.path manipulation such as
7# pygtk.require().
8#init-hook=
9
10# Add files or directories to the blacklist. They should be base names, not
11# paths.
12ignore=CVS, tox, logs, migrations
13
14# Pickle collected data for later comparisons.
15persistent=yes
16
17# List of plugins (as comma separated values of python modules names) to load,
18# usually to register additional checkers.
19load-plugins=
20
21# Use multiple processes to speed up Pylint.
22jobs=1
23
24# Allow loading of arbitrary C extensions. Extensions are imported into the
25# active Python interpreter and may run arbitrary code.
26unsafe-load-any-extension=no
27
28# A comma-separated list of package or module names from where C extensions may
29# be loaded. Extensions are loading into the active Python interpreter and may
30# run arbitrary code
31extension-pkg-whitelist=
32
33# Allow optimization of some AST trees. This will activate a peephole AST
34# optimizer, which will apply various small optimizations. For instance, it can
35# be used to obtain the result of joining multiple strings with the addition
36# operator. Joining a lot of strings can lead to a maximum recursion error in
37# Pylint and this flag can prevent that. It has one side effect, the resulting
38# AST will be different than the one from reality.
39optimize-ast=no
40
41
42[MESSAGES CONTROL]
43
44# Only show warnings with the listed confidence levels. Leave empty to show
45# all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED
46confidence=
47
48# Enable the message, report, category or checker with the given id(s). You can
49# either give multiple identifier separated by comma (,) or put this option
50# multiple time. See also the "--disable" option for examples.
51
52# old-style-class (C1001)
53# return-arg-in-generator (E0106)
54# slots-on-old-class (E1001)
55# super-on-old-class (E1002)
56# missing-super-argument (E1004)
57# print-statement (E1601)
58# parameter-unpacking (E1602)
59# unpacking-in-except (E1603)
60# old-raise-syntax (E1604)
61# backtick (E1605)
62# long-suffix (E1606)
63# old-ne-operator (E1607)
64# old-octal-literal (E1608)
65# import-star-module-level (E1609)
66# lowercase-l-suffix (W0332)
67# deprecated-module (W0402)
68# invalid-encoded-data (W0512)
69# property-on-old-class (W1001)
70# boolean-datetime (W1502)
71# deprecated-method (W1505)
72# apply-builtin (W1601)
73# basestring-builtin (W1602)
74# buffer-builtin (W1603)
75# cmp-builtin (W1604)
76# coerce-builtin (W1605)
77# execfile-builtin (W1606)
78# file-builtin (W1607)
79# long-builtin (W1608)
80# raw_input-builtin (W1609)
81# reduce-builtin (W1610)
82# standarderror-builtin (W1611)
83# unicode-builtin (W1612)
84# xrange-builtin (W1613)
85# coerce-method (W1614)
86# delslice-method (W1615)
87# getslice-method (W1616)
88# setslice-method (W1617)
89# old-division (W1619)
90# dict-iter-method (W1620)
91# dict-view-method (W1621)
92# next-method-called (W1622)
93# metaclass-assignment (W1623)
94# indexing-exception (W1624)
95# raising-string (W1625)
96# reload-builtin (W1626)
97# oct-method (W1627)
98# hex-method (W1628)
99# nonzero-method (W1629)
100# cmp-method (W1630)
101# input-builtin (W1632)
102# round-builtin (W1633)
103# intern-builtin (W1634)
104# unichr-builtin (W1635)
105# map-builtin-not-iterating (W1636)
106# zip-builtin-not-iterating (W1637)
107# range-builtin-not-iterating (W1638)
108# filter-builtin-not-iterating (W1639)
109# filter-builtin-not-iterating (W1639)
110# using-cmp-argument (W1640)
111
112enable = E0106,C1001,E1001,E1002,E1004,E1601,E1602,E1603,E1604,E1605,E1606,E1607,E1608,E1609,W0332,W0402,W0512,W1001,W1502,W1505,W1601,W1602,W1603,W1604,W1605,W1606,W1607,W1608,W1609,W1610,W1611,W1612,W1613,W1614,W1615,W1616,W1617,W1619,W1620,W1621,W1622,W1623,W1624,W1625,W1626,W1627,W1628,W1629,W1630,W1632,W1633,W1634,W1635,W1636,W1637,W1638,W1639,W1640,
113
114# Disable the message, report, category or checker with the given id(s). You
115# can either give multiple identifiers separated by comma (,) or put this
116# option multiple times (only on the command line, not in the configuration
117# file where it should appear only once).You can also use "--disable=all" to
118# disable everything first and then reenable specific checks. For example, if
119# you want to run only the similarities checker, you can use "--disable=all
120# --enable=similarities". If you want to run only the classes checker, but have
121# no Warning level messages displayed, use"--disable=all --enable=classes
122# --disable=W"
123
124# Disabling pointless reports:
125# RP0401: External dependencies
126# RP0402: Modules dependencies graph
127# RP0801: Duplication
128# R0801: Duplication
129# cyclic-import (R0401) - produces false-negative results
130
131# Disabling messages:
132# no-member (E1101) - false negative on django
133
134# pointless-string-statement (W0105)
135# unnecessary-lambda (W0108)
136# deprecated-lambda (W0110)
137# bad-builtin (W0141)
138# fixme (W0511)
139# unused-argument (W0613)
140# redefined-outer-name (W0621)
141# cell-var-from-loop (W0640)
142# bare-except (W0702)
143# broad-except (W0703)
144# logging-format-interpolation (W1202)
145# anomalous-backslash-in-string (W1401) - DO NOT ENABLE, INCORRECTLY PARSES REGEX
146# no-absolute-import (W1618):
147# import missing `from __future__ import absolute_import` Used when an import is not accompanied by from __future__ import absolute_import (default behaviour in Python 3)
148
149# invalid-name (C0103)
150# missing-docstring (C0111)
151# misplaced-comparison-constant (C0122)
152# too-many-lines (C0302)
153# bad-continuation (C0330)
154
155# too-many-ancestors (R0901)
156# too-many-instance-attributes (R0902)
157# too-many-public-methods (R0904)
158# too-few-public-methods (R0903)
159# too-many-return-statements (R0911)
160# too-many-branches (R0912)
161# too-many-arguments (R0913)
162# too-many-locals (R0914)
163# too-many-statements (R0915)
164
165# locally-disabled (I0011)
166# locally-enabled (I0012)
167
168disable=E1101,I0011,I0012,R0902,RP0401,RP0402,RP0801,R0801,W0141,W1618,W0621,W1202,W1401,W0703,W0702,C0111,W0640,C0122,W0511, W0613, C0103, R0903, C0330, C0302, R0915, R0914, R0912, W0105, R0904, R0911, W0108, W0110, R0913, R0901, R0401
169
170[REPORTS]
171
172# Set the output format. Available formats are text, parseable, colorized, msvs
173# (visual studio) and html. You can also give a reporter class, eg
174# mypackage.mymodule.MyReporterClass.
175output-format=colorized
176#output-format=parseable
177
178# Put messages in a separate file for each module / package specified on the
179# command line instead of printing them on stdout. Reports (if any) will be
180# written in a file name "pylint_global.[txt|html]".
181files-output=no
182
183# Tells whether to display a full report or only the messages
184reports=yes
185
186# Python expression which should return a note less than 10 (10 is the highest
187# note). You have access to the variables errors warning, statement which
188# respectively contain the number of errors / warnings messages and the total
189# number of statements analyzed. This is used by the global evaluation report
190# (RP0004).
191evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
192
193# Template used to display messages. This is a python new-style format string
194# used to format the message information. See doc for all details
195#msg-template=
196
197
198[VARIABLES]
199
200# Tells whether we should check for unused import in __init__ files.
201init-import=no
202
203# A regular expression matching the name of dummy variables (i.e. expectedly
204# not used).
205dummy-variables-rgx=_$|dummy
206
207# List of additional names supposed to be defined in builtins. Remember that
208# you should avoid to define new builtins when possible.
209additional-builtins=
210
211# List of strings which can identify a callback function by name. A callback
212# name must start or end with one of those strings.
213callbacks=cb_,_cb
214
215
216[TYPECHECK]
217
218# Tells whether missing members accessed in mixin class should be ignored. A
219# mixin class is detected if its name ends with "mixin" (case insensitive).
220ignore-mixin-members=yes
221
222# List of module names for which member attributes should not be checked
223# (useful for modules/projects where namespaces are manipulated during runtime
224# and thus existing member attributes cannot be deduced by static analysis. It
225# supports qualified module names, as well as Unix pattern matching.
226ignored-modules=
227
228# List of classes names for which member attributes should not be checked
229# (useful for classes with attributes dynamically set). This supports can work
230# with qualified names.
231ignored-classes=
232
233# List of members which are set dynamically and missed by pylint inference
234# system, and so shouldn't trigger E1101 when accessed. Python regular
235# expressions are accepted.
236generated-members=
237
238
239[SPELLING]
240
241# Spelling dictionary name. Available dictionaries: none. To make it working
242# install python-enchant package.
243spelling-dict=
244
245# List of comma separated words that should not be checked.
246spelling-ignore-words=
247
248# A path to a file that contains private dictionary; one word per line.
249spelling-private-dict-file=
250
251# Tells whether to store unknown words to indicated private dictionary in
252# --spelling-private-dict-file option instead of raising a message.
253spelling-store-unknown-words=no
254
255
256[SIMILARITIES]
257
258# Minimum lines number of a similarity.
259min-similarity-lines=10
260
261# Ignore comments when computing similarities.
262ignore-comments=yes
263
264# Ignore docstrings when computing similarities.
265ignore-docstrings=yes
266
267# Ignore imports when computing similarities.
268ignore-imports=no
269
270
271[MISCELLANEOUS]
272
273# List of note tags to take in consideration, separated by a comma.
274notes=FIXME,XXX,TODO
275
276
277[LOGGING]
278
279# Logging modules to check that the string format arguments are in logging
280# function parameter format
281logging-modules=logging
282
283
284[FORMAT]
285
286# Maximum number of characters on a single line.
287max-line-length=80
288
289# Regexp for a line that is allowed to be longer than the limit.
290ignore-long-lines=^\s*(# )?<?https?://\S+>?$
291
292# Allow the body of an if to be on the same line as the test if there is no
293# else.
294single-line-if-stmt=no
295
296# List of optional constructs for which whitespace checking is disabled. `dict-
297# separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
298# `trailing-comma` allows a space between comma and closing bracket: (a, ).
299# `empty-line` allows space-only lines.
300no-space-check=trailing-comma,dict-separator
301
302# Maximum number of lines in a module
303max-module-lines=1500
304
305# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
306# tab).
307indent-string=' '
308
309# Number of spaces of indent required inside a hanging or continued line.
310indent-after-paren=4
311
312# Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
313expected-line-ending-format=
314
315
316[BASIC]
317
318# List of builtins function names that should not be used, separated by a comma
319bad-functions=map,filter,input
320
321# Good variable names which should always be accepted, separated by a comma
322good-names=i,j,k,ex,Run,_,x,e,ip
323
324# Bad variable names which should always be refused, separated by a comma
325bad-names=foo,bar,baz,toto,tutu,tata
326
327# Colon-delimited sets of names that determine each other's naming style when
328# the name regexes allow several styles.
329name-group=
330
331# Include a hint for the correct naming format with invalid-name
332include-naming-hint=no
333
334# Regular expression matching correct function names
335function-rgx=[a-z_][a-z0-9_]{2,30}$
336
337# Naming hint for function names
338function-name-hint=[a-z_][a-z0-9_]{2,30}$
339
340# Regular expression matching correct variable names
341variable-rgx=[a-z_][a-z0-9_]{2,30}$
342
343# Naming hint for variable names
344variable-name-hint=[a-z_][a-z0-9_]{2,30}$
345
346# Regular expression matching correct constant names
347const-rgx=(([A-Z_][A-Z0-9_]*)|(__.*__))$
348
349# Naming hint for constant names
350const-name-hint=(([A-Z_][A-Z0-9_]*)|(__.*__))$
351
352# Regular expression matching correct attribute names
353attr-rgx=[a-z_][a-z0-9_]{2,30}$
354
355# Naming hint for attribute names
356attr-name-hint=[a-z_][a-z0-9_]{2,30}$
357
358# Regular expression matching correct argument names
359argument-rgx=[a-z_][a-z0-9_]{2,30}$
360
361# Naming hint for argument names
362argument-name-hint=[a-z_][a-z0-9_]{2,30}$
363
364# Regular expression matching correct class attribute names
365class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
366
367# Naming hint for class attribute names
368class-attribute-name-hint=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
369
370# Regular expression matching correct inline iteration names
371inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
372
373# Naming hint for inline iteration names
374inlinevar-name-hint=[A-Za-z_][A-Za-z0-9_]*$
375
376# Regular expression matching correct class names
377class-rgx=[A-Z_][a-zA-Z0-9]+$
378
379# Naming hint for class names
380class-name-hint=[A-Z_][a-zA-Z0-9]+$
381
382# Regular expression matching correct module names
383module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
384
385# Naming hint for module names
386module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
387
388# Regular expression matching correct method names
389method-rgx=[a-z_][a-z0-9_]{2,30}$
390
391# Naming hint for method names
392method-name-hint=[a-z_][a-z0-9_]{2,30}$
393
394# Regular expression which should only match function or class names that do
395# not require a docstring.
396no-docstring-rgx=^_
397
398# Minimum line length for functions/classes that require docstrings, shorter
399# ones are exempt.
400docstring-min-length=-1
401
402
403[ELIF]
404
405# Maximum number of nested blocks for function / method body
406max-nested-blocks=5
407
408
409[IMPORTS]
410
411# Deprecated modules which should not be used, separated by a comma
412deprecated-modules=regsub,TERMIOS,Bastion,rexec
413
414# Create a graph of every (i.e. internal and external) dependencies in the
415# given file (report RP0402 must not be disabled)
416import-graph=
417
418# Create a graph of external dependencies in the given file (report RP0402 must
419# not be disabled)
420ext-import-graph=
421
422# Create a graph of internal dependencies in the given file (report RP0402 must
423# not be disabled)
424int-import-graph=
425
426
427[DESIGN]
428
429# Maximum number of arguments for function / method
430max-args=10
431
432# Argument names that match this expression will be ignored. Default to name
433# with leading underscore
434ignored-argument-names=_.*
435
436# Maximum number of locals for function / method body
437max-locals=15
438
439# Maximum number of return / yield for function / method body
440max-returns=6
441
442# Maximum number of branch for function / method body
443max-branches=12
444
445# Maximum number of statements in function / method body
446max-statements=50
447
448# Maximum number of parents for a class (see R0901).
449max-parents=7
450
451# Maximum number of attributes for a class (see R0902).
452max-attributes=15
453
454# Minimum number of public methods for a class (see R0903).
455min-public-methods=2
456
457# Maximum number of public methods for a class (see R0904).
458max-public-methods=20
459
460# Maximum number of boolean expressions in a if statement
461max-bool-expr=5
462
463
464[CLASSES]
465
466# List of method names used to declare (i.e. assign) instance attributes.
467defining-attr-methods=__init__,__new__,setUp
468
469# List of valid names for the first argument in a class method.
470valid-classmethod-first-arg=cls
471
472# List of valid names for the first argument in a metaclass class method.
473valid-metaclass-classmethod-first-arg=mcs
474
475# List of member names, which should be excluded from the protected access
476# warning.
477exclude-protected=_asdict,_fields,_replace,_source,_make
478
479
480[EXCEPTIONS]
481
482# Exceptions that will emit a warning when being caught. Defaults to
483# "Exception"
484overgeneral-exceptions=Exception