Limiting the size of the cache
[theonering] / support / pylint.rc
1 # lint Python modules using external checkers.
2 #
3 # This is the main checker controling the other ones and the reports
4 # generation. It is itself both a raw checker and an astng checker in order
5 # to:
6 # * handle message activation / deactivation at the module level
7 # * handle some basic but necessary stats'data (number of classes, methods...)
8 #
9 [MASTER]
10
11 # Specify a configuration file.
12 #rcfile=
13
14 # Python code to execute, usually for sys.path manipulation such as
15 # pygtk.require().
16 #init-hook=
17
18 # Profiled execution.
19 profile=no
20
21 # Add <file or directory> to the black list. It should be a base name, not a
22 # path. You may set this option multiple times.
23 ignore=CVS
24
25 # Pickle collected data for later comparisons.
26 persistent=yes
27
28 # Set the cache size for astng objects.
29 cache-size=500
30
31 # List of plugins (as comma separated values of python modules names) to load,
32 # usually to register additional checkers.
33 load-plugins=
34
35
36 [MESSAGES CONTROL]
37
38 # Enable only checker(s) with the given id(s). This option conflicts with the
39 # disable-checker option
40 #enable-checker=
41
42 # Enable all checker(s) except those with the given id(s). This option
43 # conflicts with the enable-checker option
44 #disable-checker=
45
46 # Enable all messages in the listed categories.
47 #enable-msg-cat=
48
49 # Disable all messages in the listed categories.
50 #disable-msg-cat=
51
52 # Enable the message(s) with the given id(s).
53 #enable-msg=
54
55 # Disable the message(s) with the given id(s).
56 disable-msg=W0403,W0612,W0613,C0103,C0111,C0301,R0903,W0142,W0603,R0904,R0921,R0201
57
58 [REPORTS]
59
60 # set the output format. Available formats are text, parseable, colorized, msvs
61 # (visual studio) and html
62 output-format=colorized
63
64 # Include message's id in output
65 include-ids=yes
66
67 # Put messages in a separate file for each module / package specified on the
68 # command line instead of printing them on stdout. Reports (if any) will be
69 # written in a file name "pylint_global.[txt|html]".
70 files-output=no
71
72 # Tells wether to display a full report or only the messages
73 reports=no
74
75 # Python expression which should return a note less than 10 (10 is the highest
76 # note).You have access to the variables errors warning, statement which
77 # respectivly contain the number of errors / warnings messages and the total
78 # number of statements analyzed. This is used by the global evaluation report
79 # (R0004).
80 evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10)
81
82 # Add a comment according to your evaluation note. This is used by the global
83 # evaluation report (R0004).
84 comment=no
85
86 # Enable the report(s) with the given id(s).
87 #enable-report=
88
89 # Disable the report(s) with the given id(s).
90 #disable-report=
91
92
93 # checks for
94 # * unused variables / imports
95 # * undefined variables
96 # * redefinition of variable from builtins or from an outer scope
97 # * use of variable before assigment
98 #
99 [VARIABLES]
100
101 # Tells wether we should check for unused import in __init__ files.
102 init-import=no
103
104 # A regular expression matching names used for dummy variables (i.e. not used).
105 dummy-variables-rgx=_|dummy
106
107 # List of additional names supposed to be defined in builtins. Remember that
108 # you should avoid to define new builtins when possible.
109 additional-builtins=
110
111
112 # checks for :
113 # * doc strings
114 # * modules / classes / functions / methods / arguments / variables name
115 # * number of arguments, local variables, branchs, returns and statements in
116 # functions, methods
117 # * required module attributes
118 # * dangerous default values as arguments
119 # * redefinition of function / method / class
120 # * uses of the global statement
121 #
122 [BASIC]
123
124 # Required attributes for module, separated by a comma
125 required-attributes=
126
127 # Regular expression which should only match functions or classes name which do
128 # not require a docstring
129 no-docstring-rgx=__.*__
130
131 # Regular expression which should only match correct module names
132 module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$
133
134 # Regular expression which should only match correct module level names
135 const-rgx=(([A-Z_][A-Z1-9_]*)|(__.*__))$
136
137 # Regular expression which should only match correct class names
138 class-rgx=[A-Z_][a-zA-Z0-9]+$
139
140 # Regular expression which should only match correct function names
141 function-rgx=[a-z_][a-z0-9_]{2,30}$
142
143 # Regular expression which should only match correct method names
144 method-rgx=[a-z_][a-z0-9_]{2,30}$
145
146 # Regular expression which should only match correct instance attribute names
147 attr-rgx=[a-z_][a-zA-Z0-9_]{2,30}$
148
149 # Regular expression which should only match correct argument names
150 argument-rgx=[a-z_][a-zA-Z0-9_]{2,30}$
151
152 # Regular expression which should only match correct variable names
153 variable-rgx=[a-z_][a-zA-Z0-9_]{2,30}$
154
155 # Regular expression which should only match correct list comprehension /
156 # generator expression variable names
157 inlinevar-rgx=[A-Za-z_][A-Za-z0-9_]*$
158
159 # Good variable names which should always be accepted, separated by a comma
160 good-names=i,j,k,ex,Run,_
161
162 # Bad variable names which should always be refused, separated by a comma
163 bad-names=foo,bar,baz,toto,tutu,tata
164
165 # List of builtins function names that should not be used, separated by a comma
166 bad-functions=map,filter,apply,input
167
168
169 # try to find bugs in the code using type inference
170
171 [TYPECHECK]
172
173 # Tells wether missing members accessed in mixin class should be ignored. A
174 # mixin class is detected if its name ends with "mixin" (case insensitive).
175 ignore-mixin-members=yes
176
177 # When zope mode is activated, consider the acquired-members option to ignore
178 # access to some undefined attributes.
179 zope=no
180
181 # List of members which are usually get through zope's acquisition mecanism and
182 # so shouldn't trigger E0201 when accessed (need zope=yes to be considered).
183 acquired-members=REQUEST,acl_users,aq_parent
184
185
186 # checks for sign of poor/misdesign:
187 # * number of methods, attributes, local variables...
188 # * size, complexity of functions, methods
189 #
190 [DESIGN]
191
192 # Maximum number of arguments for function / method
193 max-args=5
194
195 # Maximum number of locals for function / method body
196 max-locals=15
197
198 # Maximum number of return / yield for function / method body
199 max-returns=6
200
201 # Maximum number of branch for function / method body
202 max-branchs=12
203
204 # Maximum number of statements in function / method body
205 max-statements=50
206
207 # Maximum number of parents for a class (see R0901).
208 max-parents=7
209
210 # Maximum number of attributes for a class (see R0902).
211 max-attributes=15
212
213 # Minimum number of public methods for a class (see R0903).
214 min-public-methods=1
215
216 # Maximum number of public methods for a class (see R0904).
217 max-public-methods=20
218
219
220 # checks for :
221 # * methods without self as first argument
222 # * overridden methods signature
223 # * access only to existant members via self
224 # * attributes not defined in the __init__ method
225 # * supported interfaces implementation
226 # * unreachable code
227 #
228 [CLASSES]
229
230 # List of interface methods to ignore, separated by a comma. This is used for
231 # instance to not check methods defines in Zope's Interface base class.
232 ignore-iface-methods=isImplementedBy,deferred,extends,names,namesAndDescriptions,queryDescriptionFor,getBases,getDescriptionFor,getDoc,getName,getTaggedValue,getTaggedValueTags,isEqualOrExtendedBy,setTaggedValue,isImplementedByInstancesOf,adaptWith,is_implemented_by
233
234 # List of method names used to declare (i.e. assign) instance attributes.
235 defining-attr-methods=__init__,__new__,setUp
236
237
238 # checks for
239 # * external modules dependencies
240 # * relative / wildcard imports
241 # * cyclic imports
242 # * uses of deprecated modules
243 #
244 [IMPORTS]
245
246 # Deprecated modules which should not be used, separated by a comma
247 deprecated-modules=regsub,string,TERMIOS,Bastion,rexec
248
249 # Create a graph of every (i.e. internal and external) dependencies in the
250 # given file (report R0402 must not be disabled)
251 import-graph=
252
253 # Create a graph of external dependencies in the given file (report R0402 must
254 # not be disabled)
255 ext-import-graph=
256
257 # Create a graph of internal dependencies in the given file (report R0402 must
258 # not be disabled)
259 int-import-graph=
260
261
262 # checks for similarities and duplicated code. This computation may be
263 # memory / CPU intensive, so you should disable it if you experiments some
264 # problems.
265 #
266 [SIMILARITIES]
267
268 # Minimum lines number of a similarity.
269 min-similarity-lines=4
270
271 # Ignore comments when computing similarities.
272 ignore-comments=yes
273
274 # Ignore docstrings when computing similarities.
275 ignore-docstrings=yes
276
277
278 # checks for:
279 # * warning notes in the code like FIXME, XXX
280 # * PEP 263: source code with non ascii character but no encoding declaration
281 #
282 [MISCELLANEOUS]
283
284 # List of note tags to take in consideration, separated by a comma.
285 notes=FIXME,XXX,TODO
286
287
288 # checks for :
289 # * unauthorized constructions
290 # * strict indentation
291 # * line length
292 # * use of <> instead of !=
293 #
294 [FORMAT]
295
296 # Maximum number of characters on a single line.
297 # @note Limiting this to the most extreme cases
298 max-line-length=100
299
300 # Maximum number of lines in a module
301 max-module-lines=1000
302
303 # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1
304 # tab).
305 indent-string='\t'