You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

436 lines
16 KiB

  1. # SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries
  2. #
  3. # SPDX-License-Identifier: Unlicense
  4. [MASTER]
  5. # A comma-separated list of package or module names from where C extensions may
  6. # be loaded. Extensions are loading into the active Python interpreter and may
  7. # run arbitrary code
  8. extension-pkg-whitelist=hid
  9. # Add files or directories to the blacklist. They should be base names, not
  10. # paths.
  11. ignore=CVS
  12. # Add files or directories matching the regex patterns to the blacklist. The
  13. # regex matches against base names, not paths.
  14. ignore-patterns=
  15. # Python code to execute, usually for sys.path manipulation such as
  16. # pygtk.require().
  17. #init-hook=
  18. # Use multiple processes to speed up Pylint.
  19. jobs=1
  20. # List of plugins (as comma separated values of python modules names) to load,
  21. # usually to register additional checkers.
  22. load-plugins=
  23. # Pickle collected data for later comparisons.
  24. persistent=yes
  25. # Specify a configuration file.
  26. #rcfile=
  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. [MESSAGES CONTROL]
  31. # Only show warnings with the listed confidence levels. Leave empty to show
  32. # all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED
  33. confidence=
  34. # Disable the message, report, category or checker with the given id(s). You
  35. # can either give multiple identifiers separated by comma (,) or put this
  36. # option multiple times (only on the command line, not in the configuration
  37. # file where it should appear only once).You can also use "--disable=all" to
  38. # disable everything first and then reenable specific checks. For example, if
  39. # you want to run only the similarities checker, you can use "--disable=all
  40. # --enable=similarities". If you want to run only the classes checker, but have
  41. # no Warning level messages displayed, use"--disable=all --enable=classes
  42. # --disable=W"
  43. # disable=import-error,print-statement,parameter-unpacking,unpacking-in-except,old-raise-syntax,backtick,long-suffix,old-ne-operator,old-octal-literal,import-star-module-level,raw-checker-failed,bad-inline-option,locally-disabled,locally-enabled,file-ignored,suppressed-message,useless-suppression,deprecated-pragma,apply-builtin,basestring-builtin,buffer-builtin,cmp-builtin,coerce-builtin,execfile-builtin,file-builtin,long-builtin,raw_input-builtin,reduce-builtin,standarderror-builtin,unicode-builtin,xrange-builtin,coerce-method,delslice-method,getslice-method,setslice-method,no-absolute-import,old-division,dict-iter-method,dict-view-method,next-method-called,metaclass-assignment,indexing-exception,raising-string,reload-builtin,oct-method,hex-method,nonzero-method,cmp-method,input-builtin,round-builtin,intern-builtin,unichr-builtin,map-builtin-not-iterating,zip-builtin-not-iterating,range-builtin-not-iterating,filter-builtin-not-iterating,using-cmp-argument,eq-without-hash,div-method,idiv-method,rdiv-method,exception-message-attribute,invalid-str-codec,sys-max-int,bad-python3-import,deprecated-string-function,deprecated-str-translate-call
  44. disable=print-statement,parameter-unpacking,unpacking-in-except,old-raise-syntax,backtick,long-suffix,old-ne-operator,old-octal-literal,import-star-module-level,raw-checker-failed,bad-inline-option,locally-disabled,locally-enabled,file-ignored,suppressed-message,useless-suppression,deprecated-pragma,apply-builtin,basestring-builtin,buffer-builtin,cmp-builtin,coerce-builtin,execfile-builtin,file-builtin,long-builtin,raw_input-builtin,reduce-builtin,standarderror-builtin,unicode-builtin,xrange-builtin,coerce-method,delslice-method,getslice-method,setslice-method,no-absolute-import,old-division,dict-iter-method,dict-view-method,next-method-called,metaclass-assignment,indexing-exception,raising-string,reload-builtin,oct-method,hex-method,nonzero-method,cmp-method,input-builtin,round-builtin,intern-builtin,unichr-builtin,map-builtin-not-iterating,zip-builtin-not-iterating,range-builtin-not-iterating,filter-builtin-not-iterating,using-cmp-argument,eq-without-hash,div-method,idiv-method,rdiv-method,exception-message-attribute,invalid-str-codec,sys-max-int,bad-python3-import,deprecated-string-function,deprecated-str-translate-call,import-error,attribute-defined-outside-init,bad-continuation,invalid-name,import-error,import-outside-toplevel,too-many-branches,too-many-statements,too-many-public-methods
  45. # Enable the message, report, category or checker with the given id(s). You can
  46. # either give multiple identifier separated by comma (,) or put this option
  47. # multiple time (only on the command line, not in the configuration file where
  48. # it should appear only once). See also the "--disable" option for examples.
  49. enable=
  50. [REPORTS]
  51. # Python expression which should return a note less than 10 (10 is the highest
  52. # note). You have access to the variables errors warning, statement which
  53. # respectively contain the number of errors / warnings messages and the total
  54. # number of statements analyzed. This is used by the global evaluation report
  55. # (RP0004).
  56. evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
  57. # Template used to display messages. This is a python new-style format string
  58. # used to format the message information. See doc for all details
  59. #msg-template=
  60. # Set the output format. Available formats are text, parseable, colorized, json
  61. # and msvs (visual studio).You can also give a reporter class, eg
  62. # mypackage.mymodule.MyReporterClass.
  63. output-format=text
  64. # Tells whether to display a full report or only the messages
  65. reports=no
  66. # Activate the evaluation score.
  67. score=yes
  68. [REFACTORING]
  69. # Maximum number of nested blocks for function / method body
  70. max-nested-blocks=5
  71. [LOGGING]
  72. # Logging modules to check that the string format arguments are in logging
  73. # function parameter format
  74. logging-modules=logging
  75. [SPELLING]
  76. # Spelling dictionary name. Available dictionaries: none. To make it working
  77. # install python-enchant package.
  78. spelling-dict=
  79. # List of comma separated words that should not be checked.
  80. spelling-ignore-words=
  81. # A path to a file that contains private dictionary; one word per line.
  82. spelling-private-dict-file=
  83. # Tells whether to store unknown words to indicated private dictionary in
  84. # --spelling-private-dict-file option instead of raising a message.
  85. spelling-store-unknown-words=no
  86. [MISCELLANEOUS]
  87. # List of note tags to take in consideration, separated by a comma.
  88. # notes=FIXME,XXX,TODO
  89. notes=FIXME,XXX
  90. [TYPECHECK]
  91. # List of decorators that produce context managers, such as
  92. # contextlib.contextmanager. Add to this list to register other decorators that
  93. # produce valid context managers.
  94. contextmanager-decorators=contextlib.contextmanager
  95. # List of members which are set dynamically and missed by pylint inference
  96. # system, and so shouldn't trigger E1101 when accessed. Python regular
  97. # expressions are accepted.
  98. generated-members=
  99. # Tells whether missing members accessed in mixin class should be ignored. A
  100. # mixin class is detected if its name ends with "mixin" (case insensitive).
  101. ignore-mixin-members=yes
  102. # This flag controls whether pylint should warn about no-member and similar
  103. # checks whenever an opaque object is returned when inferring. The inference
  104. # can return multiple potential results while evaluating a Python object, but
  105. # some branches might not be evaluated, which results in partial inference. In
  106. # that case, it might be useful to still emit no-member and other checks for
  107. # the rest of the inferred objects.
  108. ignore-on-opaque-inference=yes
  109. # List of class names for which member attributes should not be checked (useful
  110. # for classes with dynamically set attributes). This supports the use of
  111. # qualified names.
  112. ignored-classes=optparse.Values,thread._local,_thread._local
  113. # List of module names for which member attributes should not be checked
  114. # (useful for modules/projects where namespaces are manipulated during runtime
  115. # and thus existing member attributes cannot be deduced by static analysis. It
  116. # supports qualified module names, as well as Unix pattern matching.
  117. ignored-modules=
  118. # Show a hint with possible names when a member name was not found. The aspect
  119. # of finding the hint is based on edit distance.
  120. missing-member-hint=yes
  121. # The minimum edit distance a name should have in order to be considered a
  122. # similar match for a missing member name.
  123. missing-member-hint-distance=1
  124. # The total number of similar names that should be taken in consideration when
  125. # showing a hint for a missing member.
  126. missing-member-max-choices=1
  127. [VARIABLES]
  128. # List of additional names supposed to be defined in builtins. Remember that
  129. # you should avoid to define new builtins when possible.
  130. additional-builtins=
  131. # Tells whether unused global variables should be treated as a violation.
  132. allow-global-unused-variables=yes
  133. # List of strings which can identify a callback function by name. A callback
  134. # name must start or end with one of those strings.
  135. callbacks=cb_,_cb
  136. # A regular expression matching the name of dummy variables (i.e. expectedly
  137. # not used).
  138. dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_
  139. # Argument names that match this expression will be ignored. Default to name
  140. # with leading underscore
  141. ignored-argument-names=_.*|^ignored_|^unused_
  142. # Tells whether we should check for unused import in __init__ files.
  143. init-import=no
  144. # List of qualified module names which can have objects that can redefine
  145. # builtins.
  146. redefining-builtins-modules=six.moves,future.builtins
  147. [FORMAT]
  148. # Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
  149. # expected-line-ending-format=
  150. expected-line-ending-format=LF
  151. # Regexp for a line that is allowed to be longer than the limit.
  152. ignore-long-lines=^\s*(# )?<?https?://\S+>?$
  153. # Number of spaces of indent required inside a hanging or continued line.
  154. indent-after-paren=4
  155. # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
  156. # tab).
  157. indent-string=' '
  158. # Maximum number of characters on a single line.
  159. max-line-length=100
  160. # Maximum number of lines in a module
  161. max-module-lines=1000
  162. # List of optional constructs for which whitespace checking is disabled. `dict-
  163. # separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
  164. # `trailing-comma` allows a space between comma and closing bracket: (a, ).
  165. # `empty-line` allows space-only lines.
  166. no-space-check=trailing-comma,dict-separator
  167. # Allow the body of a class to be on the same line as the declaration if body
  168. # contains single statement.
  169. single-line-class-stmt=no
  170. # Allow the body of an if to be on the same line as the test if there is no
  171. # else.
  172. single-line-if-stmt=no
  173. [SIMILARITIES]
  174. # Ignore comments when computing similarities.
  175. ignore-comments=yes
  176. # Ignore docstrings when computing similarities.
  177. ignore-docstrings=yes
  178. # Ignore imports when computing similarities.
  179. ignore-imports=no
  180. # Minimum lines number of a similarity.
  181. min-similarity-lines=12
  182. [BASIC]
  183. # Naming hint for argument names
  184. argument-name-hint=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  185. # Regular expression matching correct argument names
  186. argument-rgx=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  187. # Naming hint for attribute names
  188. attr-name-hint=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  189. # Regular expression matching correct attribute names
  190. attr-rgx=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  191. # Bad variable names which should always be refused, separated by a comma
  192. bad-names=foo,bar,baz,toto,tutu,tata
  193. # Naming hint for class attribute names
  194. class-attribute-name-hint=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
  195. # Regular expression matching correct class attribute names
  196. class-attribute-rgx=([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
  197. # Naming hint for class names
  198. # class-name-hint=[A-Z_][a-zA-Z0-9]+$
  199. class-name-hint=[A-Z_][a-zA-Z0-9_]+$
  200. # Regular expression matching correct class names
  201. # class-rgx=[A-Z_][a-zA-Z0-9]+$
  202. class-rgx=[A-Z_][a-zA-Z0-9_]+$
  203. # Naming hint for constant names
  204. const-name-hint=(([A-Z_][A-Z0-9_]*)|(__.*__))$
  205. # Regular expression matching correct constant names
  206. const-rgx=(([A-Z_][A-Z0-9_]*)|(__.*__))$
  207. # Minimum line length for functions/classes that require docstrings, shorter
  208. # ones are exempt.
  209. docstring-min-length=-1
  210. # Naming hint for function names
  211. function-name-hint=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  212. # Regular expression matching correct function names
  213. function-rgx=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  214. # Good variable names which should always be accepted, separated by a comma
  215. # good-names=i,j,k,ex,Run,_
  216. good-names=r,g,b,w,i,j,k,n,x,y,z,ex,ok,Run,_
  217. # Include a hint for the correct naming format with invalid-name
  218. include-naming-hint=no
  219. # Naming hint for inline iteration names
  220. inlinevar-name-hint=[A-Za-z_][A-Za-z0-9_]*$
  221. # Regular expression matching correct inline iteration names
  222. inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
  223. # Naming hint for method names
  224. method-name-hint=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  225. # Regular expression matching correct method names
  226. method-rgx=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  227. # Naming hint for module names
  228. module-name-hint=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
  229. # Regular expression matching correct module names
  230. module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
  231. # Colon-delimited sets of names that determine each other's naming style when
  232. # the name regexes allow several styles.
  233. name-group=
  234. # Regular expression which should only match function or class names that do
  235. # not require a docstring.
  236. no-docstring-rgx=^_
  237. # List of decorators that produce properties, such as abc.abstractproperty. Add
  238. # to this list to register other decorators that produce valid properties.
  239. property-classes=abc.abstractproperty
  240. # Naming hint for variable names
  241. variable-name-hint=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  242. # Regular expression matching correct variable names
  243. variable-rgx=(([a-z][a-z0-9_]{2,30})|(_[a-z0-9_]*))$
  244. [IMPORTS]
  245. # Allow wildcard imports from modules that define __all__.
  246. allow-wildcard-with-all=no
  247. # Analyse import fallback blocks. This can be used to support both Python 2 and
  248. # 3 compatible code, which means that the block might have code that exists
  249. # only in one or another interpreter, leading to false positives when analysed.
  250. analyse-fallback-blocks=no
  251. # Deprecated modules which should not be used, separated by a comma
  252. deprecated-modules=optparse,tkinter.tix
  253. # Create a graph of external dependencies in the given file (report RP0402 must
  254. # not be disabled)
  255. ext-import-graph=
  256. # Create a graph of every (i.e. internal and external) dependencies in the
  257. # given file (report RP0402 must not be disabled)
  258. import-graph=
  259. # Create a graph of internal dependencies in the given file (report RP0402 must
  260. # not be disabled)
  261. int-import-graph=
  262. # Force import order to recognize a module as part of the standard
  263. # compatibility libraries.
  264. known-standard-library=
  265. # Force import order to recognize a module as part of a third party library.
  266. known-third-party=enchant
  267. [CLASSES]
  268. # List of method names used to declare (i.e. assign) instance attributes.
  269. defining-attr-methods=__init__,__new__,setUp
  270. # List of member names, which should be excluded from the protected access
  271. # warning.
  272. exclude-protected=_asdict,_fields,_replace,_source,_make
  273. # List of valid names for the first argument in a class method.
  274. valid-classmethod-first-arg=cls
  275. # List of valid names for the first argument in a metaclass class method.
  276. valid-metaclass-classmethod-first-arg=mcs
  277. [DESIGN]
  278. # Maximum number of arguments for function / method
  279. max-args=5
  280. # Maximum number of attributes for a class (see R0902).
  281. # max-attributes=7
  282. max-attributes=11
  283. # Maximum number of boolean expressions in a if statement
  284. max-bool-expr=5
  285. # Maximum number of branch for function / method body
  286. max-branches=12
  287. # Maximum number of locals for function / method body
  288. max-locals=15
  289. # Maximum number of parents for a class (see R0901).
  290. max-parents=7
  291. # Maximum number of public methods for a class (see R0904).
  292. max-public-methods=20
  293. # Maximum number of return / yield for function / method body
  294. max-returns=6
  295. # Maximum number of statements in function / method body
  296. max-statements=50
  297. # Minimum number of public methods for a class (see R0903).
  298. min-public-methods=1
  299. [EXCEPTIONS]
  300. # Exceptions that will emit a warning when being caught. Defaults to
  301. # "Exception"
  302. overgeneral-exceptions=Exception