Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 1 | [MASTER] |
| 2 | |
| 3 | # Specify a configuration file. |
Samuel Marks | 9d4fbd3 | 2020-12-22 09:17:25 +1100 | [diff] [blame] | 4 | #rcfile= |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 5 | |
| 6 | # Python code to execute, usually for sys.path manipulation such as |
| 7 | # pygtk.require(). |
| 8 | #init-hook= |
| 9 | |
| 10 | # Profiled execution. |
| 11 | profile=no |
| 12 | |
Karmel Allison | 18ebe82 | 2020-07-20 15:49:15 -0700 | [diff] [blame] | 13 | # Add files or directories to the denylist. They should be base names, not |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 14 | # paths. |
| 15 | ignore=CVS |
| 16 | |
| 17 | # Pickle collected data for later comparisons. |
| 18 | persistent=yes |
| 19 | |
| 20 | # List of plugins (as comma separated values of python modules names) to load, |
| 21 | # usually to register additional checkers. |
Samuel Marks | 4d3d4e3 | 2020-12-06 09:27:30 +1100 | [diff] [blame] | 22 | load-plugins=pylint.extensions.docparams |
Samuel Marks | b70f04e | 2020-12-16 20:53:19 +1100 | [diff] [blame] | 23 | accept-no-param-doc=no |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 24 | |
| 25 | [MESSAGES CONTROL] |
| 26 | |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 27 | # Disable the message, report, category or checker with the given id(s). You |
| 28 | # can either give multiple identifiers separated by comma (,) or put this |
| 29 | # option multiple times (only on the command line, not in the configuration |
| 30 | # file where it should appear only once).You can also use "--disable=all" to |
| 31 | # disable everything first and then reenable specific checks. For example, if |
| 32 | # you want to run only the similarities checker, you can use "--disable=all |
| 33 | # --enable=similarities". If you want to run only the classes checker, but have |
| 34 | # no Warning level messages displayed, use"--disable=all --enable=classes |
| 35 | # --disable=W" |
Ian Hua | 6b51112 | 2021-08-11 21:38:50 +0100 | [diff] [blame] | 36 | disable=design,similarities,no-self-use,attribute-defined-outside-init,locally-disabled,star-args,pointless-except,bad-option-value,global-statement,fixme,suppressed-message,useless-suppression,locally-enabled,no-member,no-name-in-module,import-error,unsubscriptable-object,unbalanced-tuple-unpacking,undefined-variable,not-context-manager,invalid-sequence-index,W,R,C,I |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 37 | |
Ian Hua | 6b51112 | 2021-08-11 21:38:50 +0100 | [diff] [blame] | 38 | # Enable the message, report, category or checker with the given id(s). You can |
| 39 | # either give multiple identifier separated by comma (,) or put this option |
| 40 | # multiple time. See also the "--disable" option for examples. |
| 41 | # W0311 bad-indentation |
| 42 | # W0312 mixed-indentation |
| 43 | # C0330 bad-continuation |
| 44 | # C0301 line-too-long |
| 45 | # C0326 bad-whitespace |
| 46 | # W0611 unused-import |
| 47 | # W0622 redefined-builtin |
| 48 | enable=indexing-exception,old-raise-syntax,W0311,W0312,C0330,C0301,C0326,W0611,W0622 |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 49 | |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 50 | # Set the cache size for astng objects. |
| 51 | cache-size=500 |
| 52 | |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 53 | |
| 54 | [REPORTS] |
| 55 | |
| 56 | # Set the output format. Available formats are text, parseable, colorized, msvs |
| 57 | # (visual studio) and html. You can also give a reporter class, eg |
| 58 | # mypackage.mymodule.MyReporterClass. |
| 59 | output-format=text |
| 60 | |
| 61 | # Put messages in a separate file for each module / package specified on the |
| 62 | # command line instead of printing them on stdout. Reports (if any) will be |
| 63 | # written in a file name "pylint_global.[txt|html]". |
| 64 | files-output=no |
| 65 | |
| 66 | # Tells whether to display a full report or only the messages |
| 67 | reports=no |
| 68 | |
| 69 | # Python expression which should return a note less than 10 (10 is the highest |
| 70 | # note). You have access to the variables errors warning, statement which |
| 71 | # respectively contain the number of errors / warnings messages and the total |
| 72 | # number of statements analyzed. This is used by the global evaluation report |
| 73 | # (RP0004). |
| 74 | evaluation=10.0 - ((float(5 * error + warning + refactor + convention) / statement) * 10) |
| 75 | |
| 76 | # Add a comment according to your evaluation note. This is used by the global |
| 77 | # evaluation report (RP0004). |
| 78 | comment=no |
| 79 | |
| 80 | # Template used to display messages. This is a python new-style format string |
| 81 | # used to format the message information. See doc for all details |
| 82 | #msg-template= |
| 83 | |
| 84 | |
| 85 | [TYPECHECK] |
| 86 | |
| 87 | # Tells whether missing members accessed in mixin class should be ignored. A |
| 88 | # mixin class is detected if its name ends with "mixin" (case insensitive). |
| 89 | ignore-mixin-members=yes |
| 90 | |
| 91 | # List of classes names for which member attributes should not be checked |
| 92 | # (useful for classes with attributes dynamically set). |
| 93 | ignored-classes=SQLObject |
| 94 | |
| 95 | # When zope mode is activated, add a predefined set of Zope acquired attributes |
| 96 | # to generated-members. |
| 97 | zope=no |
| 98 | |
| 99 | # List of members which are set dynamically and missed by pylint inference |
| 100 | # system, and so shouldn't trigger E0201 when accessed. Python regular |
| 101 | # expressions are accepted. |
| 102 | generated-members=REQUEST,acl_users,aq_parent |
| 103 | |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 104 | # List of decorators that create context managers from functions, such as |
| 105 | # contextlib.contextmanager. |
| 106 | contextmanager-decorators=contextlib.contextmanager,contextlib2.contextmanager |
| 107 | |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 108 | |
| 109 | [VARIABLES] |
| 110 | |
| 111 | # Tells whether we should check for unused import in __init__ files. |
| 112 | init-import=no |
| 113 | |
| 114 | # A regular expression matching the beginning of the name of dummy variables |
| 115 | # (i.e. not used). |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 116 | dummy-variables-rgx=^\*{0,2}(_$|unused_|dummy_) |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 117 | |
| 118 | # List of additional names supposed to be defined in builtins. Remember that |
| 119 | # you should avoid to define new builtins when possible. |
| 120 | additional-builtins= |
| 121 | |
| 122 | |
| 123 | [BASIC] |
| 124 | |
| 125 | # Required attributes for module, separated by a comma |
| 126 | required-attributes= |
| 127 | |
| 128 | # List of builtins function names that should not be used, separated by a comma |
| 129 | bad-functions=apply,input,reduce |
| 130 | |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 131 | |
| 132 | # Disable the report(s) with the given id(s). |
| 133 | # All non-Google reports are disabled by default. |
| 134 | disable-report=R0001,R0002,R0003,R0004,R0101,R0102,R0201,R0202,R0220,R0401,R0402,R0701,R0801,R0901,R0902,R0903,R0904,R0911,R0912,R0913,R0914,R0915,R0921,R0922,R0923 |
| 135 | |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 136 | # Regular expression which should only match correct module names |
| 137 | module-rgx=(([a-z_][a-z0-9_]*)|([A-Z][a-zA-Z0-9]+))$ |
| 138 | |
| 139 | # Regular expression which should only match correct module level names |
| 140 | const-rgx=^(_?[A-Z][A-Z0-9_]*|__[a-z0-9_]+__|_?[a-z][a-z0-9_]*)$ |
| 141 | |
| 142 | # Regular expression which should only match correct class names |
| 143 | class-rgx=^_?[A-Z][a-zA-Z0-9]*$ |
| 144 | |
| 145 | # Regular expression which should only match correct function names |
| 146 | function-rgx=^(?:(?P<camel_case>_?[A-Z][a-zA-Z0-9]*)|(?P<snake_case>_?[a-z][a-z0-9_]*))$ |
| 147 | |
| 148 | # Regular expression which should only match correct method names |
| 149 | method-rgx=^(?:(?P<exempt>__[a-z0-9_]+__|next)|(?P<camel_case>_{0,2}[A-Z][a-zA-Z0-9]*)|(?P<snake_case>_{0,2}[a-z][a-z0-9_]*))$ |
| 150 | |
| 151 | # Regular expression which should only match correct instance attribute names |
| 152 | attr-rgx=^_{0,2}[a-z][a-z0-9_]*$ |
| 153 | |
| 154 | # Regular expression which should only match correct argument names |
| 155 | argument-rgx=^[a-z][a-z0-9_]*$ |
| 156 | |
| 157 | # Regular expression which should only match correct variable names |
| 158 | variable-rgx=^[a-z][a-z0-9_]*$ |
| 159 | |
| 160 | # Regular expression which should only match correct attribute names in class |
| 161 | # bodies |
| 162 | class-attribute-rgx=^(_?[A-Z][A-Z0-9_]*|__[a-z0-9_]+__|_?[a-z][a-z0-9_]*)$ |
| 163 | |
| 164 | # Regular expression which should only match correct list comprehension / |
| 165 | # generator expression variable names |
| 166 | inlinevar-rgx=^[a-z][a-z0-9_]*$ |
| 167 | |
| 168 | # Good variable names which should always be accepted, separated by a comma |
| 169 | good-names=main,_ |
| 170 | |
| 171 | # Bad variable names which should always be refused, separated by a comma |
| 172 | bad-names= |
| 173 | |
| 174 | # Regular expression which should only match function or class names that do |
| 175 | # not require a docstring. |
| 176 | no-docstring-rgx=(__.*__|main) |
| 177 | |
| 178 | # Minimum line length for functions/classes that require docstrings, shorter |
| 179 | # ones are exempt. |
| 180 | docstring-min-length=10 |
| 181 | |
| 182 | |
| 183 | [FORMAT] |
| 184 | |
| 185 | # Maximum number of characters on a single line. |
| 186 | max-line-length=80 |
| 187 | |
| 188 | # Regexp for a line that is allowed to be longer than the limit. |
Yifei Feng | aee7f95 | 2018-01-26 16:53:59 -0800 | [diff] [blame] | 189 | ignore-long-lines=(?x) |
| 190 | (^\s*(import|from)\s |
| 191 | |\$Id:\s\/\/depot\/.+#\d+\s\$ |
| 192 | |^[a-zA-Z_][a-zA-Z0-9_]*\s*=\s*("[^"]\S+"|'[^']\S+') |
| 193 | |^\s*\#\ LINT\.ThenChange |
| 194 | |^[^#]*\#\ type:\ [a-zA-Z_][a-zA-Z0-9_.,[\] ]*$ |
| 195 | |pylint |
| 196 | |""" |
| 197 | |\# |
| 198 | |lambda |
| 199 | |(https?|ftp):) |
Olivia Nordquist | 8016e72 | 2016-03-24 10:36:14 -0800 | [diff] [blame] | 200 | |
| 201 | # Allow the body of an if to be on the same line as the test if there is no |
| 202 | # else. |
| 203 | single-line-if-stmt=y |
| 204 | |
| 205 | # List of optional constructs for which whitespace checking is disabled |
| 206 | no-space-check= |
| 207 | |
| 208 | # Maximum number of lines in a module |
| 209 | max-module-lines=99999 |
| 210 | |
| 211 | # String used as indentation unit. This is usually " " (4 spaces) or "\t" (1 |
| 212 | # tab). |
| 213 | indent-string=' ' |
| 214 | |
| 215 | |
| 216 | [SIMILARITIES] |
| 217 | |
| 218 | # Minimum lines number of a similarity. |
| 219 | min-similarity-lines=4 |
| 220 | |
| 221 | # Ignore comments when computing similarities. |
| 222 | ignore-comments=yes |
| 223 | |
| 224 | # Ignore docstrings when computing similarities. |
| 225 | ignore-docstrings=yes |
| 226 | |
| 227 | # Ignore imports when computing similarities. |
| 228 | ignore-imports=no |
| 229 | |
| 230 | |
| 231 | [MISCELLANEOUS] |
| 232 | |
| 233 | # List of note tags to take in consideration, separated by a comma. |
| 234 | notes= |
| 235 | |
| 236 | |
| 237 | [IMPORTS] |
| 238 | |
| 239 | # Deprecated modules which should not be used, separated by a comma |
| 240 | deprecated-modules=regsub,TERMIOS,Bastion,rexec,sets |
| 241 | |
| 242 | # Create a graph of every (i.e. internal and external) dependencies in the |
| 243 | # given file (report RP0402 must not be disabled) |
| 244 | import-graph= |
| 245 | |
| 246 | # Create a graph of external dependencies in the given file (report RP0402 must |
| 247 | # not be disabled) |
| 248 | ext-import-graph= |
| 249 | |
| 250 | # Create a graph of internal dependencies in the given file (report RP0402 must |
| 251 | # not be disabled) |
| 252 | int-import-graph= |
| 253 | |
| 254 | |
| 255 | [CLASSES] |
| 256 | |
| 257 | # List of interface methods to ignore, separated by a comma. This is used for |
| 258 | # instance to not check methods defines in Zope's Interface base class. |
| 259 | ignore-iface-methods=isImplementedBy,deferred,extends,names,namesAndDescriptions,queryDescriptionFor,getBases,getDescriptionFor,getDoc,getName,getTaggedValue,getTaggedValueTags,isEqualOrExtendedBy,setTaggedValue,isImplementedByInstancesOf,adaptWith,is_implemented_by |
| 260 | |
| 261 | # List of method names used to declare (i.e. assign) instance attributes. |
| 262 | defining-attr-methods=__init__,__new__,setUp |
| 263 | |
| 264 | # List of valid names for the first argument in a class method. |
| 265 | valid-classmethod-first-arg=cls,class_ |
| 266 | |
| 267 | # List of valid names for the first argument in a metaclass class method. |
| 268 | valid-metaclass-classmethod-first-arg=mcs |
| 269 | |
| 270 | |
| 271 | [DESIGN] |
| 272 | |
| 273 | # Maximum number of arguments for function / method |
| 274 | max-args=5 |
| 275 | |
| 276 | # Argument names that match this expression will be ignored. Default to name |
| 277 | # with leading underscore |
| 278 | ignored-argument-names=_.* |
| 279 | |
| 280 | # Maximum number of locals for function / method body |
| 281 | max-locals=15 |
| 282 | |
| 283 | # Maximum number of return / yield for function / method body |
| 284 | max-returns=6 |
| 285 | |
| 286 | # Maximum number of branch for function / method body |
| 287 | max-branches=12 |
| 288 | |
| 289 | # Maximum number of statements in function / method body |
| 290 | max-statements=50 |
| 291 | |
| 292 | # Maximum number of parents for a class (see R0901). |
| 293 | max-parents=7 |
| 294 | |
| 295 | # Maximum number of attributes for a class (see R0902). |
| 296 | max-attributes=7 |
| 297 | |
| 298 | # Minimum number of public methods for a class (see R0903). |
| 299 | min-public-methods=2 |
| 300 | |
| 301 | # Maximum number of public methods for a class (see R0904). |
| 302 | max-public-methods=20 |
| 303 | |
| 304 | |
| 305 | [EXCEPTIONS] |
| 306 | |
| 307 | # Exceptions that will emit a warning when being caught. Defaults to |
| 308 | # "Exception" |
| 309 | overgeneral-exceptions=Exception,StandardError,BaseException |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 310 | |
| 311 | |
| 312 | [AST] |
| 313 | |
| 314 | # Maximum line length for lambdas |
| 315 | short-func-length=1 |
| 316 | |
| 317 | # List of module members that should be marked as deprecated. |
| 318 | # All of the string functions are listed in 4.1.4 Deprecated string functions |
| 319 | # in the Python 2.4 docs. |
| 320 | deprecated-members=string.atof,string.atoi,string.atol,string.capitalize,string.expandtabs,string.find,string.rfind,string.index,string.rindex,string.count,string.lower,string.split,string.rsplit,string.splitfields,string.join,string.joinfields,string.lstrip,string.rstrip,string.strip,string.swapcase,string.translate,string.upper,string.ljust,string.rjust,string.center,string.zfill,string.replace,sys.exitfunc |
| 321 | |
| 322 | |
| 323 | [DOCSTRING] |
| 324 | |
Samuel Marks | 4d3d4e3 | 2020-12-06 09:27:30 +1100 | [diff] [blame] | 325 | default-docstring-type=google |
A. Unique TensorFlower | 81d9a24 | 2017-01-03 12:33:21 -0800 | [diff] [blame] | 326 | # List of exceptions that do not need to be mentioned in the Raises section of |
| 327 | # a docstring. |
| 328 | ignore-exceptions=AssertionError,NotImplementedError,StopIteration,TypeError |
| 329 | |
| 330 | |
| 331 | |
| 332 | [TOKENS] |
| 333 | |
| 334 | # Number of spaces of indent required when the last token on the preceding line |
| 335 | # is an open (, [, or {. |
| 336 | indent-after-paren=4 |
| 337 | |
| 338 | |
| 339 | [GOOGLE LINES] |
| 340 | |
| 341 | # Regexp for a proper copyright notice. |
Charles Nicholson | 0ac2d9b | 2017-04-10 09:29:49 -0800 | [diff] [blame] | 342 | copyright=Copyright \d{4} The TensorFlow Authors\. +All [Rr]ights [Rr]eserved\. |