Release: | 2.10 |
---|---|
Date: | TBA |
Added
unspecified-encoding
: Emitted when open() is called without specifying an encodingCloses #3826
Added
use-list-literal
: Emitted whenlist()
is called with no arguments instead of using[]
Closes #4365
Added
use-dict-literal
: Emitted whendict()
is called with no arguments instead of using{}
Closes #4365
Added optional extension
consider-ternary-expression
: Emitted whenever a variable is assigned in both branches of an if/else block.Closes # 4366
Added optional extension
while-used
: Emitted whenever awhile
loop is used.Closes # 4367
Added
forgotten-debug-statement
: Emitted whenbreakpoint
,pdb.set_trace
orsys.breakpointhook
calls are foundCloses #3692
Added
use-sequence-for-iteration
: Emitted when iterating over an in-place definedset
.Added
consider-using-f-string
: Emitted when .format() or '%' is being used to format a string.Closes #3592
CodeStyleChecker
- Limit
consider-using-tuple
to be emitted only for in-place definedlists
. - Emit
consider-using-tuple
even if list contains astarred
expression.
- Limit
pyreverse now permit to produce colored generated diagram by using the
colorized
option.Pyreverse - add output in PlantUML format
consider-using-with
is no longer triggered if a context manager is returned from a function.pylint does not crash with a traceback anymore when a file is problematic. It creates a template text file for opening an issue on the bug tracker instead. The linting can go on for other non problematic files instead of being impossible.
Pyreverse - Show class has-a relationships inferred from type-hints
Performance of the Similarity checker has been improved.
Added
time.clock
to deprecated functions/methods for python 3.3Added
ignored-parents
option to the design checker to ignore specific classes from thetoo-many-ancestors
check (R0901).Don't emit
no-member
error if guarded behind if statement.Ref #1162 Closes #1990 Closes #4168
Fix false positives for
superfluous-parens
with walrus operator, ternary operator and inside list comprehension.Closes #2818 Closes #3249 Closes #3608 Closes #4346
Refactor of
--list-msgs
&--list-msgs-enabled
: both options now show whether messages are emittable with the current interpreter.Closes #4778
Fix false negative for
used-before-assignment
when the variable is assigned in an exception handler, but used outside of the handler.Closes #626
Added
disable-next
option: allows using # pylint: disable-next=msgid to disable a message for the following lineCloses #1682
Added
format-string-without-interpolation
checker: Emitted when formatting is applied to a string without any variables to be replacedCloses #4042
Added
redundant-u-string-prefix
checker: Emitted when the u prefix is added to a stringCloses #4102
Fixed
cell-var-from-loop
checker: handle cell variables in comprehensions within functions, and function default argument expressions. Also handle basic variable shadowing.Closes #2846 Closes #3107
Fixed bug with
cell-var-from-loop
checker: it no longer has false negatives when bothunused-variable
andused-before-assignment
are disabled.Class methods' signatures are now ignored the same way as functions' with similarities "ignore-signatures" option enabled
Closes #4653