1
1
[MASTER]
2
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.
12
+ ignore =CVS
13
+
14
+ # Add files or directories matching the regex patterns to the blacklist. The
15
+ # regex matches against base names, not paths.
16
+ ignore-patterns =
17
+
3
18
# Pickle collected data for later comparisons.
4
19
persistent =yes
5
20
21
+ # List of plugins (as comma separated values of python modules names) to load,
22
+ # usually to register additional checkers.
23
+ load-plugins =
24
+
25
+ # Use multiple processes to speed up Pylint.
26
+ jobs =1
27
+
28
+ # Allow loading of arbitrary C extensions. Extensions are imported into the
29
+ # active Python interpreter and may run arbitrary code.
30
+ unsafe-load-any-extension =no
31
+
32
+ # A comma-separated list of package or module names from where C extensions may
33
+ # be loaded. Extensions are loading into the active Python interpreter and may
34
+ # run arbitrary code
35
+ extension-pkg-whitelist =
36
+
37
+ # Allow optimization of some AST trees. This will activate a peephole AST
38
+ # optimizer, which will apply various small optimizations. For instance, it can
39
+ # be used to obtain the result of joining multiple strings with the addition
40
+ # operator. Joining a lot of strings can lead to a maximum recursion error in
41
+ # Pylint and this flag can prevent that. It has one side effect, the resulting
42
+ # AST will be different than the one from reality. This option is deprecated
43
+ # and it will be removed in Pylint 2.0.
44
+ optimize-ast =no
45
+
6
46
7
47
[MESSAGES CONTROL]
8
48
49
+ # Only show warnings with the listed confidence levels. Leave empty to show
50
+ # all. Valid levels: HIGH, INFERENCE, INFERENCE_FAILURE, UNDEFINED
51
+ confidence =
52
+
9
53
# Enable the message, report, category or checker with the given id(s). You can
10
54
# either give multiple identifier separated by comma (,) or put this option
11
- # multiple time. See also the "--disable" option for examples.
55
+ # multiple time (only on the command line, not in the configuration file where
56
+ # it should appear only once). See also the "--disable" option for examples.
12
57
# enable=
13
58
14
59
# Disable the message, report, category or checker with the given id(s). You
@@ -20,10 +65,7 @@ persistent=yes
20
65
# --enable=similarities". If you want to run only the classes checker, but have
21
66
# no Warning level messages displayed, use"--disable=all --enable=classes
22
67
# --disable=W"
23
-
24
- # Disable "doc"strings warning for constants
25
- # Disable duplicate code warnings
26
- disable =W0105,R0801
68
+ disable =cmp-method,print-statement,coerce-builtin,parameter-unpacking,old-ne-operator,map-builtin-not-iterating,buffer-builtin,getslice-method,basestring-builtin,reduce-builtin,old-octal-literal,xrange-builtin,unpacking-in-except,apply-builtin,filter-builtin-not-iterating,execfile-builtin,pointless-string-statement,intern-builtin,old-division,round-builtin,using-cmp-argument,standarderror-builtin,reload-builtin,old-raise-syntax,input-builtin,no-absolute-import,import-star-module-level,long-builtin,dict-view-method,long-suffix,backtick,duplicate-code,raising-string,metaclass-assignment,cmp-builtin,raw_input-builtin,dict-iter-method,delslice-method,coerce-method,setslice-method,zip-builtin-not-iterating,unichr-builtin,useless-suppression,oct-method,file-builtin,suppressed-message,hex-method,next-method-called,unicode-builtin,range-builtin-not-iterating,indexing-exception,nonzero-method
27
69
28
70
29
71
[REPORTS]
@@ -35,7 +77,8 @@ output-format=colorized
35
77
36
78
# Put messages in a separate file for each module / package specified on the
37
79
# command line instead of printing them on stdout. Reports (if any) will be
38
- # written in a file name "pylint_global.[txt|html]".
80
+ # written in a file name "pylint_global.[txt|html]". This option is deprecated
81
+ # and it will be removed in Pylint 2.0.
39
82
files-output =no
40
83
41
84
# Tells whether to display a full report or only the messages
@@ -53,68 +96,84 @@ evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / stateme
53
96
msg-template ={msg_id}:{line:3d},{column:2d}: {msg} ({symbol})
54
97
55
98
56
- [VARIABLES ]
99
+ [BASIC ]
57
100
58
- # Tells whether we should check for unused import in __init__ files.
59
- init-import =no
101
+ # Good variable names which should always be accepted, separated by a comma
102
+ good-names =i,j,k,ex,Run,_
60
103
61
- # A regular expression matching the beginning of the name of dummy variables
62
- # (i.e. not used).
63
- dummy-variables-rgx =_$|dummy
104
+ # Bad variable names which should always be refused, separated by a comma
105
+ bad-names =foo,bar,baz,toto,tutu,tata
64
106
65
- # List of additional names supposed to be defined in builtins. Remember that
66
- # you should avoid to define new builtins when possible .
67
- additional-builtins =
107
+ # Colon-delimited sets of names that determine each other's naming style when
108
+ # the name regexes allow several styles .
109
+ name-group =
68
110
111
+ # Include a hint for the correct naming format with invalid-name
112
+ include-naming-hint =no
69
113
70
- [MISCELLANEOUS]
114
+ # List of decorators that produce properties, such as abc.abstractproperty. Add
115
+ # to this list to register other decorators that produce valid properties.
116
+ property-classes =abc.abstractproperty
71
117
72
- # List of note tags to take in consideration, separated by a comma.
73
- notes =FIXME,XXX,TODO
118
+ # Regular expression matching correct attribute names
119
+ attr-rgx =[a-z_][a-z0-9_]{2,30}$
74
120
121
+ # Naming hint for attribute names
122
+ attr-name-hint =[a-z_][a-z0-9_]{2,30}$
75
123
76
- [BASIC]
124
+ # Regular expression matching correct class attribute names
125
+ class-attribute-rgx =([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
77
126
78
- # List of builtins function names that should not be used, separated by a comma
79
- bad-functions =map,filter,apply,input
127
+ # Naming hint for class attribute names
128
+ class-attribute-name-hint =([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
80
129
81
- # Regular expression which should only match correct module names
82
- module -rgx =(( [a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+)) $
130
+ # Regular expression matching correct function names
131
+ function -rgx =[a-z_][a-z0-9_]{2,30} $
83
132
84
- # Regular expression which should only match correct module level names
85
- const-rgx =(([A-Z_][A-Z0-9_]*)|(__.*__))$
133
+ # Naming hint for function names
134
+ function-name-hint =[a-z_][a-z0-9_]{2,30}$
135
+
136
+ # Regular expression matching correct inline iteration names
137
+ inlinevar-rgx =[A-Za-z_][A-Za-z0-9_]*$
138
+
139
+ # Naming hint for inline iteration names
140
+ inlinevar-name-hint =[A-Za-z_][A-Za-z0-9_]*$
86
141
87
- # Regular expression which should only match correct class names
142
+ # Regular expression matching correct class names
88
143
class-rgx =[A-Z_][a-zA-Z0-9]+$
89
144
90
- # Regular expression which should only match correct function names
91
- function-rgx =[a-z_ ][a-z0-9_]{2,30} $
145
+ # Naming hint for class names
146
+ class-name-hint =[A-Z_ ][a-zA-Z0-9]+ $
92
147
93
- # Regular expression which should only match correct method names
148
+ # Regular expression matching correct method names
94
149
method-rgx =[a-z_][a-z0-9_]{2,30}$
95
150
96
- # Regular expression which should only match correct instance attribute names
97
- attr-rgx =[a-z_][a-z0-9_]{2,30}$
151
+ # Naming hint for method names
152
+ method-name-hint =[a-z_][a-z0-9_]{2,30}$
98
153
99
- # Regular expression which should only match correct argument names
154
+ # Regular expression matching correct argument names
100
155
argument-rgx =[a-z_][a-z0-9_]{2,30}$
101
156
102
- # Regular expression which should only match correct variable names
103
- variable-rgx =[a-z_][a-z0-9_]{2,30}$
157
+ # Naming hint for argument names
158
+ argument-name-hint =[a-z_][a-z0-9_]{2,30}$
104
159
105
- # Regular expression which should only match correct attribute names in class
106
- # bodies
107
- class-attribute-rgx =([A-Za-z_][A-Za-z0-9_]{2,30}|(__.*__))$
160
+ # Regular expression matching correct constant names
161
+ const-rgx =(([A-Z_][A-Z0-9_]*)|(__.*__))$
108
162
109
- # Regular expression which should only match correct list comprehension /
110
- # generator expression variable names
111
- inlinevar-rgx =[A-Za-z_][A-Za-z0-9_]*$
163
+ # Naming hint for constant names
164
+ const-name-hint =(([A-Z_][A-Z0-9_]*)|(__.*__))$
112
165
113
- # Good variable names which should always be accepted, separated by a comma
114
- good-names =i,j,k,ex,Run,_
166
+ # Regular expression matching correct module names
167
+ module-rgx =(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
115
168
116
- # Bad variable names which should always be refused, separated by a comma
117
- bad-names =foo,bar,baz,toto,tutu,tata
169
+ # Naming hint for module names
170
+ module-name-hint =(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
171
+
172
+ # Regular expression matching correct variable names
173
+ variable-rgx =[a-z_][a-z0-9_]{2,30}$
174
+
175
+ # Naming hint for variable names
176
+ variable-name-hint =[a-z_][a-z0-9_]{2,30}$
118
177
119
178
# Regular expression which should only match function or class names that do
120
179
# not require a docstring.
@@ -125,20 +184,10 @@ no-docstring-rgx=__.*__
125
184
docstring-min-length =-1
126
185
127
186
128
- [TYPECHECK ]
187
+ [ELIF ]
129
188
130
- # Tells whether missing members accessed in mixin class should be ignored. A
131
- # mixin class is detected if its name ends with "mixin" (case insensitive).
132
- ignore-mixin-members =yes
133
-
134
- # List of classes names for which member attributes should not be checked
135
- # (useful for classes with attributes dynamically set).
136
- ignored-classes =SQLObject
137
-
138
- # List of members which are set dynamically and missed by pylint inference
139
- # system, and so shouldn't trigger E0201 when accessed. Python regular
140
- # expressions are accepted.
141
- generated-members =REQUEST,acl_users,aq_parent
189
+ # Maximum number of nested blocks for function / method body
190
+ max-nested-blocks =5
142
191
143
192
144
193
[FORMAT]
@@ -153,16 +202,38 @@ ignore-long-lines=^\s*(# )?<?https?://\S+>?$
153
202
# else.
154
203
single-line-if-stmt =no
155
204
156
- # List of optional constructs for which whitespace checking is disabled
205
+ # List of optional constructs for which whitespace checking is disabled. `dict-
206
+ # separator` is used to allow tabulation in dicts, etc.: {1 : 1,\n222: 2}.
207
+ # `trailing-comma` allows a space between comma and closing bracket: (a, ).
208
+ # `empty-line` allows space-only lines.
157
209
no-space-check =trailing-comma,dict-separator
158
210
159
211
# Maximum number of lines in a module
160
212
max-module-lines =1000
161
213
162
- # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
214
+ # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
163
215
# tab).
164
216
indent-string =' '
165
217
218
+ # Number of spaces of indent required inside a hanging or continued line.
219
+ indent-after-paren =4
220
+
221
+ # Expected format of line ending, e.g. empty (any line ending), LF or CRLF.
222
+ expected-line-ending-format =
223
+
224
+
225
+ [LOGGING]
226
+
227
+ # Logging modules to check that the string format arguments are in logging
228
+ # function parameter format
229
+ logging-modules =logging
230
+
231
+
232
+ [MISCELLANEOUS]
233
+
234
+ # List of note tags to take in consideration, separated by a comma.
235
+ notes =FIXME,XXX,TODO
236
+
166
237
167
238
[SIMILARITIES]
168
239
@@ -179,6 +250,89 @@ ignore-docstrings=yes
179
250
ignore-imports =no
180
251
181
252
253
+ [SPELLING]
254
+
255
+ # Spelling dictionary name. Available dictionaries: none. To make it working
256
+ # install python-enchant package.
257
+ spelling-dict =
258
+
259
+ # List of comma separated words that should not be checked.
260
+ spelling-ignore-words =
261
+
262
+ # A path to a file that contains private dictionary; one word per line.
263
+ spelling-private-dict-file =
264
+
265
+ # Tells whether to store unknown words to indicated private dictionary in
266
+ # --spelling-private-dict-file option instead of raising a message.
267
+ spelling-store-unknown-words =no
268
+
269
+
270
+ [TYPECHECK]
271
+
272
+ # Tells whether missing members accessed in mixin class should be ignored. A
273
+ # mixin class is detected if its name ends with "mixin" (case insensitive).
274
+ ignore-mixin-members =yes
275
+
276
+ # List of module names for which member attributes should not be checked
277
+ # (useful for modules/projects where namespaces are manipulated during runtime
278
+ # and thus existing member attributes cannot be deduced by static analysis. It
279
+ # supports qualified module names, as well as Unix pattern matching.
280
+ ignored-modules =
281
+
282
+ # List of class names for which member attributes should not be checked (useful
283
+ # for classes with dynamically set attributes). This supports the use of
284
+ # qualified names.
285
+ ignored-classes =SQLObject
286
+
287
+ # List of members which are set dynamically and missed by pylint inference
288
+ # system, and so shouldn't trigger E1101 when accessed. Python regular
289
+ # expressions are accepted.
290
+ generated-members =REQUEST,acl_users,aq_parent
291
+
292
+ # List of decorators that produce context managers, such as
293
+ # contextlib.contextmanager. Add to this list to register other decorators that
294
+ # produce valid context managers.
295
+ contextmanager-decorators =contextlib.contextmanager
296
+
297
+
298
+ [VARIABLES]
299
+
300
+ # Tells whether we should check for unused import in __init__ files.
301
+ init-import =no
302
+
303
+ # A regular expression matching the name of dummy variables (i.e. expectedly
304
+ # not used).
305
+ dummy-variables-rgx =_$|dummy
306
+
307
+ # List of additional names supposed to be defined in builtins. Remember that
308
+ # you should avoid to define new builtins when possible.
309
+ additional-builtins =
310
+
311
+ # List of strings which can identify a callback function by name. A callback
312
+ # name must start or end with one of those strings.
313
+ callbacks =cb_,_cb
314
+
315
+ # List of qualified module names which can have objects that can redefine
316
+ # builtins.
317
+ redefining-builtins-modules =six.moves,future.builtins
318
+
319
+
320
+ [CLASSES]
321
+
322
+ # List of method names used to declare (i.e. assign) instance attributes.
323
+ defining-attr-methods =__init__,__new__,setUp
324
+
325
+ # List of valid names for the first argument in a class method.
326
+ valid-classmethod-first-arg =cls
327
+
328
+ # List of valid names for the first argument in a metaclass class method.
329
+ valid-metaclass-classmethod-first-arg =mcs
330
+
331
+ # List of member names, which should be excluded from the protected access
332
+ # warning.
333
+ exclude-protected =_asdict,_fields,_replace,_source,_make
334
+
335
+
182
336
[DESIGN]
183
337
184
338
# Maximum number of arguments for function / method
@@ -212,17 +366,8 @@ min-public-methods=2
212
366
# Maximum number of public methods for a class (see R0904).
213
367
max-public-methods =20
214
368
215
-
216
- [CLASSES]
217
-
218
- # List of method names used to declare (i.e. assign) instance attributes.
219
- defining-attr-methods =__init__,__new__,setUp
220
-
221
- # List of valid names for the first argument in a class method.
222
- valid-classmethod-first-arg =cls
223
-
224
- # List of valid names for the first argument in a metaclass class method.
225
- valid-metaclass-classmethod-first-arg =mcs
369
+ # Maximum number of boolean expressions in a if statement
370
+ max-bool-expr =5
226
371
227
372
228
373
[IMPORTS]
@@ -242,6 +387,18 @@ ext-import-graph=
242
387
# not be disabled)
243
388
int-import-graph =
244
389
390
+ # Force import order to recognize a module as part of the standard
391
+ # compatibility libraries.
392
+ known-standard-library =
393
+
394
+ # Force import order to recognize a module as part of a third party library.
395
+ known-third-party =enchant
396
+
397
+ # Analyse import fallback blocks. This can be used to support both Python 2 and
398
+ # 3 compatible code, which means that the block might have code that exists
399
+ # only in one or another interpreter, leading to false positives when analysed.
400
+ analyse-fallback-blocks =no
401
+
245
402
246
403
[EXCEPTIONS]
247
404
0 commit comments