blob: cac6c6416d91e0590e94a619fb213161df3a1f94 [file] [log] [blame]
Wyatt Heplerb627b412019-11-27 09:41:25 -08001[MASTER]
2
3# A comma-separated list of package or module names from where C extensions may
4# be loaded. Extensions are loading into the active Python interpreter and may
5# run arbitrary code.
6extension-pkg-whitelist=mypy
7
8# Add files or directories to the blacklist. They should be base names, not
9# paths.
10ignore=CVS
11
12# Add files or directories matching the regex patterns to the blacklist. The
13# regex matches against base names, not paths.
14ignore-patterns=
15
16# Python code to execute, usually for sys.path manipulation such as
17# pygtk.require().
18#init-hook=
19
20# Use multiple processes to speed up Pylint. Specifying 0 will auto-detect the
21# number of processors available to use.
22jobs=0
23
24# Control the amount of potential inferred values when inferring a single
25# object. This can help the performance when dealing with large functions or
26# complex, nested conditions.
27limit-inference-results=100
28
29# List of plugins (as comma separated values of python module names) to load,
30# usually to register additional checkers.
31load-plugins=
32
33# Pickle collected data for later comparisons.
34persistent=yes
35
36# Specify a configuration file.
37#rcfile=
38
39# When enabled, pylint would attempt to guess common misconfiguration and emit
40# user-friendly hints instead of false-positive error messages.
41suggestion-mode=yes
42
43# Allow loading of arbitrary C extensions. Extensions are imported into the
44# active Python interpreter and may run arbitrary code.
45unsafe-load-any-extension=no
46
47
48[MESSAGES CONTROL]
49
50# Only show warnings with the listed confidence levels. Leave empty to show
51# all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED.
52confidence=
53
54# Disable the message, report, category or checker with the given id(s). You
55# can either give multiple identifiers separated by comma (,) or put this
56# option multiple times (only on the command line, not in the configuration
57# file where it should appear only once). You can also use "--disable=all" to
58# disable everything first and then reenable specific checks. For example, if
59# you want to run only the similarities checker, you can use "--disable=all
60# --enable=similarities". If you want to run only the classes checker, but have
61# no Warning level messages displayed, use "--disable=all --enable=classes
62# --disable=W".
63disable=fixme,
64 subprocess-run-check
65
66# Enable the message, report, category or checker with the given id(s). You can
67# either give multiple identifier separated by comma (,) or put this option
68# multiple time (only on the command line, not in the configuration file where
69# it should appear only once). See also the "--disable" option for examples.
70enable=c-extension-no-member
71
72
73[REPORTS]
74
75# Python expression which should return a score less than or equal to 10. You
76# have access to the variables 'error', 'warning', 'refactor', and 'convention'
77# which contain the number of messages in each category, as well as 'statement'
78# which is the total number of statements analyzed. This score is used by the
79# global evaluation report (RP0004).
80evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
81
82# Template used to display messages. This is a python new-style format string
83# used to format the message information. See doc for all details.
84#msg-template=
85
86# Set the output format. Available formats are text, parseable, colorized, json
87# and msvs (visual studio). You can also give a reporter class, e.g.
88# mypackage.mymodule.MyReporterClass.
89output-format=text
90
91# Tells whether to display a full report or only the messages.
92reports=no
93
94# Activate the evaluation score.
95score=no
96
97
98[REFACTORING]
99
100# Maximum number of nested blocks for function / method body
101max-nested-blocks=5
102
103# Complete name of functions that never returns. When checking for
104# inconsistent-return-statements if a never returning function is called then
105# it will be considered as an explicit return statement and no message will be
106# printed.
107never-returning-functions=sys.exit
108
109
110[FORMAT]
111
112# Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
113expected-line-ending-format=LF
114
115# Regexp for a line that is allowed to be longer than the limit.
116ignore-long-lines=^\s*(# )?<?https?://\S+>?$
117
118# Number of spaces of indent required inside a hanging or continued line.
119indent-after-paren=4
120
121# String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
122# tab).
123indent-string=' '
124
125# Maximum number of characters on a single line.
126max-line-length=80
127
128# Maximum number of lines in a module.
129max-module-lines=9999
130
131# List of optional constructs for which whitespace checking is disabled. `dict-
132# separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
133# `trailing-comma` allows a space between comma and closing bracket: (a, ).
134# `empty-line` allows space-only lines.
135no-space-check=trailing-comma,
136 dict-separator
137
138# Allow the body of a class to be on the same line as the declaration if body
139# contains single statement.
140single-line-class-stmt=no
141
142# Allow the body of an if to be on the same line as the test if there is no
143# else.
144single-line-if-stmt=no
145
146
147[VARIABLES]
148
149# List of additional names supposed to be defined in builtins. Remember that
150# you should avoid defining new builtins when possible.
151additional-builtins=
152
153# Tells whether unused global variables should be treated as a violation.
154allow-global-unused-variables=yes
155
156# List of strings which can identify a callback function by name. A callback
157# name must start or end with one of those strings.
158callbacks=cb_,
159 _cb
160
161# A regular expression matching the name of dummy variables (i.e. expected to
162# not be used).
163dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_
164
165# Argument names that match this expression will be ignored. Default to name
166# with leading underscore.
167ignored-argument-names=_.*|^ignored_|^unused_
168
169# Tells whether we should check for unused import in __init__ files.
170init-import=no
171
172# List of qualified module names which can have objects that can redefine
173# builtins.
174redefining-builtins-modules=six.moves,past.builtins,future.builtins,builtins,io
175
176
177[SPELLING]
178
179# Limits count of emitted suggestions for spelling mistakes.
180max-spelling-suggestions=4
181
182# Spelling dictionary name. Available dictionaries: none. To make it work,
183# install the python-enchant package.
184spelling-dict=
185
186# List of comma separated words that should not be checked.
187spelling-ignore-words=
188
189# A path to a file that contains the private dictionary; one word per line.
190spelling-private-dict-file=
191
192# Tells whether to store unknown words to the private dictionary (see the
193# --spelling-private-dict-file option) instead of raising a message.
194spelling-store-unknown-words=no
195
196
197[LOGGING]
198
199# Format style used to check logging format string. `old` means using %
200# formatting, `new` is for `{}` formatting,and `fstr` is for f-strings.
201logging-format-style=old
202
203# Logging modules to check that the string format arguments are in logging
204# function parameter format.
205logging-modules=logging
206
207
208[SIMILARITIES]
209
210# Ignore comments when computing similarities.
211ignore-comments=yes
212
213# Ignore docstrings when computing similarities.
214ignore-docstrings=yes
215
216# Ignore imports when computing similarities.
217ignore-imports=no
218
219# Minimum lines number of a similarity.
220min-similarity-lines=4
221
222
223[MISCELLANEOUS]
224
225# List of note tags to take in consideration, separated by a comma.
226notes=FIXME,
227 XXX,
228 TODO
229
230
231[STRING]
232
233# This flag controls whether the implicit-str-concat-in-sequence should
234# generate a warning on implicit string concatenation in sequences defined over
235# several lines.
236check-str-concat-over-line-jumps=no
237
238
239[BASIC]
240
241# Naming style matching correct argument names.
242argument-naming-style=snake_case
243
244# Regular expression matching correct argument names. Overrides argument-
245# naming-style.
246#argument-rgx=
247
248# Naming style matching correct attribute names.
249attr-naming-style=snake_case
250
251# Regular expression matching correct attribute names. Overrides attr-naming-
252# style.
253#attr-rgx=
254
255# Bad variable names which should always be refused, separated by a comma.
256bad-names=foo,
257 bar,
258 baz,
259 toto,
260 tutu,
261 tata
262
263# Naming style matching correct class attribute names.
264class-attribute-naming-style=any
265
266# Regular expression matching correct class attribute names. Overrides class-
267# attribute-naming-style.
268#class-attribute-rgx=
269
270# Naming style matching correct class names.
271class-naming-style=PascalCase
272
273# Regular expression matching correct class names. Overrides class-naming-
274# style.
275#class-rgx=
276
277# Naming style matching correct constant names.
278const-naming-style=UPPER_CASE
279
280# Regular expression matching correct constant names. Overrides const-naming-
281# style.
Wyatt Hepler8635af92019-12-05 16:32:44 -0800282const-rgx=^(_?[A-Z][A-Z0-9_]*|__[a-z0-9_]+__|_?[a-z][a-z0-9_]*)$
Wyatt Heplerb627b412019-11-27 09:41:25 -0800283
284# Minimum line length for functions/classes that require docstrings, shorter
285# ones are exempt.
286docstring-min-length=30
287
288# Naming style matching correct function names.
289function-naming-style=snake_case
290
291# Regular expression matching correct function names. Overrides function-
292# naming-style.
293#function-rgx=
294
295# Good variable names which should always be accepted, separated by a comma.
296good-names=i,
297 j,
298 k,
299 ex,
300 fd,
301 Run,
302 _
303
304# Include a hint for the correct naming format with invalid-name.
305include-naming-hint=no
306
307# Naming style matching correct inline iteration names.
308inlinevar-naming-style=any
309
310# Regular expression matching correct inline iteration names. Overrides
311# inlinevar-naming-style.
312#inlinevar-rgx=
313
314# Naming style matching correct method names.
315method-naming-style=snake_case
316
317# Regular expression matching correct method names. Overrides method-naming-
318# style.
319#method-rgx=
320
321# Naming style matching correct module names.
322module-naming-style=snake_case
323
324# Regular expression matching correct module names. Overrides module-naming-
325# style.
326#module-rgx=
327
328# Colon-delimited sets of names that determine each other's naming style when
329# the name regexes allow several styles.
330name-group=
331
332# Regular expression which should only match function or class names that do
333# not require a docstring.
334no-docstring-rgx=^_
335
336# List of decorators that produce properties, such as abc.abstractproperty. Add
337# to this list to register other decorators that produce valid properties.
338# These decorators are taken in consideration only for invalid-name.
339property-classes=abc.abstractproperty
340
341# Naming style matching correct variable names.
342variable-naming-style=snake_case
343
344# Regular expression matching correct variable names. Overrides variable-
345# naming-style.
346#variable-rgx=
347
348
349[TYPECHECK]
350
351# List of decorators that produce context managers, such as
352# contextlib.contextmanager. Add to this list to register other decorators that
353# produce valid context managers.
354contextmanager-decorators=contextlib.contextmanager
355
356# List of members which are set dynamically and missed by pylint inference
357# system, and so shouldn't trigger E1101 when accessed. Python regular
358# expressions are accepted.
359generated-members=
360
361# Tells whether missing members accessed in mixin class should be ignored. A
362# mixin class is detected if its name ends with "mixin" (case insensitive).
363ignore-mixin-members=yes
364
365# Tells whether to warn about missing members when the owner of the attribute
366# is inferred to be None.
367ignore-none=yes
368
369# This flag controls whether pylint should warn about no-member and similar
370# checks whenever an opaque object is returned when inferring. The inference
371# can return multiple potential results while evaluating a Python object, but
372# some branches might not be evaluated, which results in partial inference. In
373# that case, it might be useful to still emit no-member and other checks for
374# the rest of the inferred objects.
375ignore-on-opaque-inference=yes
376
377# List of class names for which member attributes should not be checked (useful
378# for classes with dynamically set attributes). This supports the use of
379# qualified names.
380ignored-classes=optparse.Values,thread._local,_thread._local
381
382# List of module names for which member attributes should not be checked
383# (useful for modules/projects where namespaces are manipulated during runtime
384# and thus existing member attributes cannot be deduced by static analysis). It
385# supports qualified module names, as well as Unix pattern matching.
386ignored-modules=
387
388# Show a hint with possible names when a member name was not found. The aspect
389# of finding the hint is based on edit distance.
390missing-member-hint=yes
391
392# The minimum edit distance a name should have in order to be considered a
393# similar match for a missing member name.
394missing-member-hint-distance=1
395
396# The total number of similar names that should be taken in consideration when
397# showing a hint for a missing member.
398missing-member-max-choices=1
399
400# List of decorators that change the signature of a decorated function.
401signature-mutators=
402
403
404[DESIGN]
405
406# Maximum number of arguments for function / method.
407max-args=10
408
409# Maximum number of attributes for a class (see R0902).
410max-attributes=11
411
412# Maximum number of boolean expressions in an if statement (see R0916).
413max-bool-expr=5
414
415# Maximum number of branch for function / method body.
416max-branches=25
417
418# Maximum number of locals for function / method body.
419max-locals=25
420
421# Maximum number of parents for a class (see R0901).
422max-parents=7
423
424# Maximum number of public methods for a class (see R0904).
425max-public-methods=25
426
427# Maximum number of return / yield for function / method body.
428max-returns=10
429
430# Maximum number of statements in function / method body.
431max-statements=100
432
433# Minimum number of public methods for a class (see R0903).
434min-public-methods=1
435
436
437[CLASSES]
438
439# List of method names used to declare (i.e. assign) instance attributes.
440defining-attr-methods=__init__,
441 __new__,
442 setUp,
443 __post_init__
444
445# List of member names, which should be excluded from the protected access
446# warning.
447exclude-protected=_asdict,
448 _fields,
449 _replace,
450 _source,
451 _make
452
453# List of valid names for the first argument in a class method.
454valid-classmethod-first-arg=cls
455
456# List of valid names for the first argument in a metaclass class method.
457valid-metaclass-classmethod-first-arg=cls
458
459
460[IMPORTS]
461
462# List of modules that can be imported at any level, not just the top level
463# one.
464allow-any-import-level=
465
466# Allow wildcard imports from modules that define __all__.
467allow-wildcard-with-all=no
468
469# Analyse import fallback blocks. This can be used to support both Python 2 and
470# 3 compatible code, which means that the block might have code that exists
471# only in one or another interpreter, leading to false positives when analysed.
472analyse-fallback-blocks=no
473
474# Deprecated modules which should not be used, separated by a comma.
475deprecated-modules=optparse,tkinter.tix
476
477# Create a graph of external dependencies in the given file (report RP0402 must
478# not be disabled).
479ext-import-graph=
480
481# Create a graph of every (i.e. internal and external) dependencies in the
482# given file (report RP0402 must not be disabled).
483import-graph=
484
485# Create a graph of internal dependencies in the given file (report RP0402 must
486# not be disabled).
487int-import-graph=
488
489# Force import order to recognize a module as part of the standard
490# compatibility libraries.
491known-standard-library=
492
493# Force import order to recognize a module as part of a third party library.
494known-third-party=enchant
495
496# Couples of modules and preferred modules, separated by a comma.
497preferred-modules=
498
499
500[EXCEPTIONS]
501
502# Exceptions that will emit a warning when being caught. Defaults to
503# "BaseException, Exception".
504overgeneral-exceptions=BaseException,
505 Exception