Debian Codegraph @

.pylintrc

raw
1 # Pylint 2.17.x configuration file
2 #
3 # This file is generated by l2tdevtools update-dependencies.py, any dependency
4 # related changes should be made in dependencies.ini.
5 [MAIN]
6
7 # Analyse import fallback blocks. This can be used to support both Python 2 and
8 # 3 compatible code, which means that the block might have code that exists
9 # only in one or another interpreter, leading to false positives when analysed.
10 analyse-fallback-blocks=no
11
12 # Clear in-memory caches upon conclusion of linting. Useful if running pylint
13 # in a server-like mode.
14 clear-cache-post-run=no
15
16 # Load and enable all available extensions. Use --list-extensions to see a list
17 # all available extensions.
18 #enable-all-extensions=
19
20 # In error mode, messages with a category besides ERROR or FATAL are
21 # suppressed, and no reports are done by default. Error mode is compatible with
22 # disabling specific errors.
23 #errors-only=
24
25 # Always return a 0 (non-error) status code, even if lint errors are found.
26 # This is primarily useful in continuous integration scripts.
27 #exit-zero=
28
29 # A comma-separated list of package or module names from where C extensions may
30 # be loaded. Extensions are loading into the active Python interpreter and may
31 # run arbitrary code.
32 extension-pkg-allow-list=
33
34 # A comma-separated list of package or module names from where C extensions may
35 # be loaded. Extensions are loading into the active Python interpreter and may
36 # run arbitrary code. (This is an alternative name to extension-pkg-allow-list
37 # for backward compatibility.)
38 extension-pkg-whitelist=
39
40 # Return non-zero exit code if any of these messages/categories are detected,
41 # even if score is above --fail-under value. Syntax same as enable. Messages
42 # specified are enabled, while categories only check already-enabled messages.
43 fail-on=
44
45 # Specify a score threshold under which the program will exit with error.
46 fail-under=10
47
48 # Interpret the stdin as a python script, whose filename needs to be passed as
49 # the module_or_package argument.
50 #from-stdin=
51
52 # Files or directories to be skipped. They should be base names, not paths.
53 ignore=CVS
54
55 # Add files or directories matching the regular expressions patterns to the
56 # ignore-list. The regex matches against paths and can be in Posix or Windows
57 # format. Because '\\' represents the directory delimiter on Windows systems,
58 # it can't be used as an escape character.
59 ignore-paths=
60
61 # Files or directories matching the regular expression patterns are skipped.
62 # The regex matches against base names, not paths. The default value ignores
63 # Emacs file locks
64 ignore-patterns=^\.#
65
66 # List of module names for which member attributes should not be checked
67 # (useful for modules/projects where namespaces are manipulated during runtime
68 # and thus existing member attributes cannot be deduced by static analysis). It
69 # supports qualified module names, as well as Unix pattern matching.
70 ignored-modules=
71
72 # Python code to execute, usually for sys.path manipulation such as
73 # pygtk.require().
74 #init-hook=
75
76 # Use multiple processes to speed up Pylint. Specifying 0 will auto-detect the
77 # number of processors available to use, and will cap the count on Windows to
78 # avoid hangs.
79 jobs=1
80
81 # Control the amount of potential inferred values when inferring a single
82 # object. This can help the performance when dealing with large functions or
83 # complex, nested conditions.
84 limit-inference-results=100
85
86 # List of plugins (as comma separated values of python module names) to load,
87 # usually to register additional checkers.
88 # load-plugins=
89 load-plugins=pylint.extensions.docparams
90
91 # Pickle collected data for later comparisons.
92 persistent=yes
93
94 # Minimum Python version to use for version dependent checks. Will default to
95 # the version used to run pylint.
96 py-version=3.11
97
98 # Discover python modules and packages in the file system subtree.
99 # recursive=no
100 recursive=yes
101
102 # Add paths to the list of the source roots. Supports globbing patterns. The
103 # source root is an absolute path or a path relative to the current working
104 # directory used to determine a package namespace for modules located under the
105 # source root.
106 source-roots=
107
108 # When enabled, pylint would attempt to guess common misconfiguration and emit
109 # user-friendly hints instead of false-positive error messages.
110 suggestion-mode=yes
111
112 # Allow loading of arbitrary C extensions. Extensions are imported into the
113 # active Python interpreter and may run arbitrary code.
114 unsafe-load-any-extension=no
115
116 # In verbose mode, extra non-checker-related info will be displayed.
117 #verbose=
118
119
120 [BASIC]
121
122 # Naming style matching correct argument names.
123 argument-naming-style=snake_case
124
125 # Regular expression matching correct argument names. Overrides argument-
126 # naming-style. If left empty, argument names will be checked with the set
127 # naming style.
128 #argument-rgx=
129 argument-rgx=(([a-z][a-z0-9_]*)|(_[a-z0-9_]*))$
130
131 # Naming style matching correct attribute names.
132 attr-naming-style=snake_case
133
134 # Regular expression matching correct attribute names. Overrides attr-naming-
135 # style. If left empty, attribute names will be checked with the set naming
136 # style.
137 #attr-rgx=
138 attr-rgx=(([a-z][a-z0-9_]*)|(_[a-z0-9_]*))$
139
140 # Bad variable names which should always be refused, separated by a comma.
141 bad-names=foo,
142 bar,
143 baz,
144 toto,
145 tutu,
146 tata
147
148 # Bad variable names regexes, separated by a comma. If names match any regex,
149 # they will always be refused
150 bad-names-rgxs=
151
152 # Naming style matching correct class attribute names.
153 class-attribute-naming-style=any
154
155 # Regular expression matching correct class attribute names. Overrides class-
156 # attribute-naming-style. If left empty, class attribute names will be checked
157 # with the set naming style.
158 #class-attribute-rgx=
159 class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]*|(__.*__))$
160
161 # Naming style matching correct class constant names.
162 class-const-naming-style=UPPER_CASE
163
164 # Regular expression matching correct class constant names. Overrides class-
165 # const-naming-style. If left empty, class constant names will be checked with
166 # the set naming style.
167 #class-const-rgx=
168
169 # Naming style matching correct class names.
170 class-naming-style=PascalCase
171
172 # Regular expression matching correct class names. Overrides class-naming-
173 # style. If left empty, class names will be checked with the set naming style.
174 #class-rgx=
175 class-rgx=[A-Z_][a-zA-Z0-9]+$
176
177 # Naming style matching correct constant names.
178 const-naming-style=UPPER_CASE
179
180 # Regular expression matching correct constant names. Overrides const-naming-
181 # style. If left empty, constant names will be checked with the set naming
182 # style.
183 #const-rgx=
184 const-rgx=(([a-zA-Z_][a-zA-Z0-9_]*)|(__.*__))$
185
186 # Minimum line length for functions/classes that require docstrings, shorter
187 # ones are exempt.
188 docstring-min-length=-1
189
190 # Naming style matching correct function names.
191 function-naming-style=snake_case
192
193 # Regular expression matching correct function names. Overrides function-
194 # naming-style. If left empty, function names will be checked with the set
195 # naming style.
196 #function-rgx=
197 function-rgx=[A-Z_][a-zA-Z0-9_]*$
198
199 # Good variable names which should always be accepted, separated by a comma.
200 good-names=i,
201 j,
202 k,
203 ex,
204 Run,
205 _
206
207 # Good variable names regexes, separated by a comma. If names match any regex,
208 # they will always be accepted
209 good-names-rgxs=
210
211 # Include a hint for the correct naming format with invalid-name.
212 include-naming-hint=no
213
214 # Naming style matching correct inline iteration names.
215 inlinevar-naming-style=any
216
217 # Regular expression matching correct inline iteration names. Overrides
218 # inlinevar-naming-style. If left empty, inline iteration names will be checked
219 # with the set naming style.
220 #inlinevar-rgx=
221 inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
222
223 # Naming style matching correct method names.
224 method-naming-style=snake_case
225
226 # Regular expression matching correct method names. Overrides method-naming-
227 # style. If left empty, method names will be checked with the set naming style.
228 #method-rgx=
229 method-rgx=(test|[A-Z_])[a-zA-Z0-9_]*$
230
231 # Naming style matching correct module names.
232 module-naming-style=snake_case
233
234 # Regular expression matching correct module names. Overrides module-naming-
235 # style. If left empty, module names will be checked with the set naming style.
236 #module-rgx=
237 module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
238
239 # Colon-delimited sets of names that determine each other's naming style when
240 # the name regexes allow several styles.
241 name-group=
242
243 # Regular expression which should only match function or class names that do
244 # not require a docstring.
245 no-docstring-rgx=^_
246
247 # List of decorators that produce properties, such as abc.abstractproperty. Add
248 # to this list to register other decorators that produce valid properties.
249 # These decorators are taken in consideration only for invalid-name.
250 property-classes=abc.abstractproperty
251
252 # Regular expression matching correct type alias names. If left empty, type
253 # alias names will be checked with the set naming style.
254 #typealias-rgx=
255
256 # Regular expression matching correct type variable names. If left empty, type
257 # variable names will be checked with the set naming style.
258 #typevar-rgx=
259
260 # Naming style matching correct variable names.
261 variable-naming-style=snake_case
262
263 # Regular expression matching correct variable names. Overrides variable-
264 # naming-style. If left empty, variable names will be checked with the set
265 # naming style.
266 #variable-rgx=
267 variable-rgx=(([a-z][a-z0-9_]*)|(_[a-z0-9_]*))$
268
269
270 [CLASSES]
271
272 # Warn about protected attribute access inside special methods
273 check-protected-access-in-special-methods=no
274
275 # List of method names used to declare (i.e. assign) instance attributes.
276 defining-attr-methods=__init__,
277 __new__,
278 setUp,
279 asyncSetUp,
280 __post_init__
281
282 # List of member names, which should be excluded from the protected access
283 # warning.
284 exclude-protected=_asdict,_fields,_replace,_source,_make,os._exit
285
286 # List of valid names for the first argument in a class method.
287 valid-classmethod-first-arg=cls
288
289 # List of valid names for the first argument in a metaclass class method.
290 # valid-metaclass-classmethod-first-arg=mcs
291 valid-metaclass-classmethod-first-arg=cls
292
293
294 [DESIGN]
295
296 # List of regular expressions of class ancestor names to ignore when counting
297 # public methods (see R0903)
298 exclude-too-few-public-methods=
299
300 # List of qualified class names to ignore when counting class parents (see
301 # R0901)
302 ignored-parents=
303
304 # Maximum number of arguments for function / method.
305 # max-args=5
306 max-args=10
307
308 # Maximum number of attributes for a class (see R0902).
309 max-attributes=7
310
311 # Maximum number of boolean expressions in an if statement (see R0916).
312 max-bool-expr=5
313
314 # Maximum number of branch for function / method body.
315 max-branches=12
316
317 # Maximum number of locals for function / method body.
318 max-locals=15
319
320 # Maximum number of parents for a class (see R0901).
321 max-parents=7
322
323 # Maximum number of public methods for a class (see R0904).
324 max-public-methods=20
325
326 # Maximum number of return / yield for function / method body.
327 max-returns=6
328
329 # Maximum number of statements in function / method body.
330 max-statements=50
331
332 # Minimum number of public methods for a class (see R0903).
333 min-public-methods=2
334
335
336 [EXCEPTIONS]
337
338 # Exceptions that will emit a warning when caught.
339 overgeneral-exceptions=builtins.BaseException,builtins.Exception
340
341
342 [FORMAT]
343
344 # Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
345 expected-line-ending-format=
346
347 # Regexp for a line that is allowed to be longer than the limit.
348 ignore-long-lines=^\s*(# )?<?https?://\S+>?$
349
350 # Number of spaces of indent required inside a hanging or continued line.
351 indent-after-paren=4
352
353 # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
354 # tab).
355 # indent-string=' '
356 indent-string=' '
357
358 # Maximum number of characters on a single line.
359 # max-line-length=100
360 max-line-length=80
361
362 # Maximum number of lines in a module.
363 max-module-lines=1000
364
365 # Allow the body of a class to be on the same line as the declaration if body
366 # contains single statement.
367 single-line-class-stmt=no
368
369 # Allow the body of an if to be on the same line as the test if there is no
370 # else.
371 single-line-if-stmt=no
372
373
374 [IMPORTS]
375
376 # List of modules that can be imported at any level, not just the top level
377 # one.
378 allow-any-import-level=
379
380 # Allow explicit reexports by alias from a package __init__.
381 allow-reexport-from-package=no
382
383 # Allow wildcard imports from modules that define __all__.
384 allow-wildcard-with-all=no
385
386 # Deprecated modules which should not be used, separated by a comma.
387 deprecated-modules=
388
389 # Output a graph (.gv or any supported image format) of external dependencies
390 # to the given file (report RP0402 must not be disabled).
391 ext-import-graph=
392
393 # Output a graph (.gv or any supported image format) of all (i.e. internal and
394 # external) dependencies to the given file (report RP0402 must not be
395 # disabled).
396 import-graph=
397
398 # Output a graph (.gv or any supported image format) of internal dependencies
399 # to the given file (report RP0402 must not be disabled).
400 int-import-graph=
401
402 # Force import order to recognize a module as part of the standard
403 # compatibility libraries.
404 known-standard-library=
405
406 # Force import order to recognize a module as part of a third party library.
407 known-third-party=enchant
408
409 # Couples of modules and preferred modules, separated by a comma.
410 preferred-modules=
411
412
413 [LOGGING]
414
415 # The type of string formatting that logging methods do. `old` means using %
416 # formatting, `new` is for `{}` formatting.
417 logging-format-style=old
418
419 # Logging modules to check that the string format arguments are in logging
420 # function parameter format.
421 logging-modules=logging
422
423
424 [MESSAGES CONTROL]
425
426 # Only show warnings with the listed confidence levels. Leave empty to show
427 # all. Valid levels: HIGH, CONTROL_FLOW, INFERENCE, INFERENCE_FAILURE,
428 # UNDEFINED.
429 confidence=HIGH,
430 CONTROL_FLOW,
431 INFERENCE,
432 INFERENCE_FAILURE,
433 UNDEFINED
434
435 # Disable the message, report, category or checker with the given id(s). You
436 # can either give multiple identifiers separated by comma (,) or put this
437 # option multiple times (only on the command line, not in the configuration
438 # file where it should appear only once). You can also use "--disable=all" to
439 # disable everything first and then re-enable specific checks. For example, if
440 # you want to run only the similarities checker, you can use "--disable=all
441 # --enable=similarities". If you want to run only the classes checker, but have
442 # no Warning level messages displayed, use "--disable=all --enable=classes
443 # --disable=W".
444 disable=assignment-from-none,
445 bad-inline-option,
446 consider-using-f-string,
447 deprecated-pragma,
448 duplicate-code,
449 file-ignored,
450 fixme,
451 locally-disabled,
452 logging-format-interpolation,
453 logging-fstring-interpolation,
454 missing-param-doc,
455 raise-missing-from,
456 raw-checker-failed,
457 super-with-arguments,
458 suppressed-message,
459 too-few-public-methods,
460 too-many-ancestors,
461 too-many-boolean-expressions,
462 too-many-branches,
463 too-many-instance-attributes,
464 too-many-lines,
465 too-many-locals,
466 too-many-nested-blocks,
467 too-many-public-methods,
468 too-many-return-statements,
469 too-many-statements,
470 unsubscriptable-object,
471 useless-object-inheritance,
472 useless-suppression,
473 use-symbolic-message-instead
474
475 # Enable the message, report, category or checker with the given id(s). You can
476 # either give multiple identifier separated by comma (,) or put this option
477 # multiple time (only on the command line, not in the configuration file where
478 # it should appear only once). See also the "--disable" option for examples.
479 enable=c-extension-no-member
480
481
482 [METHOD_ARGS]
483
484 # List of qualified names (i.e., library.method) which require a timeout
485 # parameter e.g. 'requests.api.get,requests.api.post'
486 timeout-methods=requests.api.delete,requests.api.get,requests.api.head,requests.api.options,requests.api.patch,requests.api.post,requests.api.put,requests.api.request
487
488
489 [MISCELLANEOUS]
490
491 # List of note tags to take in consideration, separated by a comma.
492 notes=FIXME,
493 XXX,
494 TODO
495
496 # Regular expression of note tags to take in consideration.
497 notes-rgx=
498
499
500 [REFACTORING]
501
502 # Maximum number of nested blocks for function / method body
503 max-nested-blocks=5
504
505 # Complete name of functions that never returns. When checking for
506 # inconsistent-return-statements if a never returning function is called then
507 # it will be considered as an explicit return statement and no message will be
508 # printed.
509 never-returning-functions=sys.exit,argparse.parse_error
510
511
512 [REPORTS]
513
514 # Python expression which should return a score less than or equal to 10. You
515 # have access to the variables 'fatal', 'error', 'warning', 'refactor',
516 # 'convention', and 'info' which contain the number of messages in each
517 # category, as well as 'statement' which is the total number of statements
518 # analyzed. This score is used by the global evaluation report (RP0004).
519 evaluation=max(0, 0 if fatal else 10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10))
520
521 # Template used to display messages. This is a python new-style format string
522 # used to format the message information. See doc for all details.
523 msg-template=
524
525 # Set the output format. Available formats are text, parseable, colorized, json
526 # and msvs (visual studio). You can also give a reporter class, e.g.
527 # mypackage.mymodule.MyReporterClass.
528 #output-format=
529
530 # Tells whether to display a full report or only the messages.
531 reports=no
532
533 # Activate the evaluation score.
534 # score=yes
535 score=no
536
537
538 [SIMILARITIES]
539
540 # Comments are removed from the similarity computation
541 ignore-comments=yes
542
543 # Docstrings are removed from the similarity computation
544 ignore-docstrings=yes
545
546 # Imports are removed from the similarity computation
547 ignore-imports=yes
548
549 # Signatures are removed from the similarity computation
550 ignore-signatures=yes
551
552 # Minimum lines number of a similarity.
553 min-similarity-lines=4
554
555
556 [SPELLING]
557
558 # Limits count of emitted suggestions for spelling mistakes.
559 max-spelling-suggestions=4
560
561 # Spelling dictionary name. Available dictionaries: en_AG (hunspell), en_AU
562 # (hunspell), en_BS (hunspell), en_BW (hunspell), en_BZ (hunspell), en_CA
563 # (hunspell), en_DK (hunspell), en_GB (hunspell), en_GH (hunspell), en_HK
564 # (hunspell), en_IE (hunspell), en_IN (hunspell), en_JM (hunspell), en_MW
565 # (hunspell), en_NA (hunspell), en_NG (hunspell), en_NZ (hunspell), en_PH
566 # (hunspell), en_SG (hunspell), en_TT (hunspell), en_US (hunspell), en_ZA
567 # (hunspell), en_ZM (hunspell), en_ZW (hunspell).
568 spelling-dict=
569
570 # List of comma separated words that should be considered directives if they
571 # appear at the beginning of a comment and should not be checked.
572 spelling-ignore-comment-directives=fmt: on,fmt: off,noqa:,noqa,nosec,isort:skip,mypy:
573
574 # List of comma separated words that should not be checked.
575 spelling-ignore-words=
576
577 # A path to a file that contains the private dictionary; one word per line.
578 spelling-private-dict-file=
579
580 # Tells whether to store unknown words to the private dictionary (see the
581 # --spelling-private-dict-file option) instead of raising a message.
582 spelling-store-unknown-words=no
583
584
585 [STRING]
586
587 # This flag controls whether inconsistent-quotes generates a warning when the
588 # character used as a quote delimiter is used inconsistently within a module.
589 check-quote-consistency=no
590
591 # This flag controls whether the implicit-str-concat should generate a warning
592 # on implicit string concatenation in sequences defined over several lines.
593 check-str-concat-over-line-jumps=no
594
595
596 [TYPECHECK]
597
598 # List of decorators that produce context managers, such as
599 # contextlib.contextmanager. Add to this list to register other decorators that
600 # produce valid context managers.
601 contextmanager-decorators=contextlib.contextmanager
602
603 # List of members which are set dynamically and missed by pylint inference
604 # system, and so shouldn't trigger E1101 when accessed. Python regular
605 # expressions are accepted.
606 generated-members=
607
608 # Tells whether to warn about missing members when the owner of the attribute
609 # is inferred to be None.
610 ignore-none=yes
611
612 # This flag controls whether pylint should warn about no-member and similar
613 # checks whenever an opaque object is returned when inferring. The inference
614 # can return multiple potential results while evaluating a Python object, but
615 # some branches might not be evaluated, which results in partial inference. In
616 # that case, it might be useful to still emit no-member and other checks for
617 # the rest of the inferred objects.
618 ignore-on-opaque-inference=yes
619
620 # List of symbolic message names to ignore for Mixin members.
621 ignored-checks-for-mixins=no-member,
622 not-async-context-manager,
623 not-context-manager,
624 attribute-defined-outside-init
625
626 # List of class names for which member attributes should not be checked (useful
627 # for classes with dynamically set attributes). This supports the use of
628 # qualified names.
629 ignored-classes=optparse.Values,thread._local,_thread._local,argparse.Namespace
630
631 # Show a hint with possible names when a member name was not found. The aspect
632 # of finding the hint is based on edit distance.
633 missing-member-hint=yes
634
635 # The minimum edit distance a name should have in order to be considered a
636 # similar match for a missing member name.
637 missing-member-hint-distance=1
638
639 # The total number of similar names that should be taken in consideration when
640 # showing a hint for a missing member.
641 missing-member-max-choices=1
642
643 # Regex pattern to define which classes are considered mixins.
644 mixin-class-rgx=.*[Mm]ixin
645
646 # List of decorators that change the signature of a decorated function.
647 signature-mutators=
648
649
650 [VARIABLES]
651
652 # List of additional names supposed to be defined in builtins. Remember that
653 # you should avoid defining new builtins when possible.
654 additional-builtins=
655
656 # Tells whether unused global variables should be treated as a violation.
657 allow-global-unused-variables=yes
658
659 # List of names allowed to shadow builtins
660 allowed-redefined-builtins=
661
662 # List of strings which can identify a callback function by name. A callback
663 # name must start or end with one of those strings.
664 callbacks=cb_,
665 _cb
666
667 # A regular expression matching the name of dummy variables (i.e. expected to
668 # not be used).
669 dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_
670
671 # Argument names that match this expression will be ignored.
672 ignored-argument-names=_.*|^ignored_|^unused_
673
674 # Tells whether we should check for unused import in __init__ files.
675 init-import=no
676
677 # List of qualified module names which can have objects that can redefine
678 # builtins.
679 redefining-builtins-modules=six.moves,past.builtins,future.builtins,builtins,io