Release branch for 2.17.5 #8887
Merged
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
What's new in Pylint 2.17.5?
Release date: 2023-07-26
False Positives Fixed
Fix a false positive for
unused-variable
when there is an import in aif TYPE_CHECKING:
block andallow-global-unused-variables
is set tono
in the configuration.Closes False positive
unused-variable
forTYPE_CHECKING
imports #8696Fix false positives generated when supplying arguments as
**kwargs
to IOcalls like open().
Closes False positive
unspecified-encoding
when passing encoding as kwarg #8719Fix a false positive where pylint was ignoring method calls annotated as
NoReturn
during theinconsistent-return-statements
check.Closes False positive for
inconsistent-return-statements
with method annotated withNoReturn
return type #8747Exempt parents with only type annotations from the
invalid-enum-extension
message.
Closes False positive
invalid-enum-extension
for Enum parent class with annotations #8830Other Bug Fixes
Fixed crash when a call to
super()
was placed after an operator (e.g.not
).Closes Crash using
isinstance
+super
due to Astroid #8554Fix crash for
modified-while-iterating
checker when deletingmembers of a dict returned from a call.
Closes Crash: AttributeError: 'Call' object has no attribute 'name' #8598
Fix crash in
invalid-metaclass
check when a metaclass had duplicatebases.
Closes Crash "Fatal error while checking" with metaclass #8698
Avoid
consider-using-f-string
on modulos with brackets in template.Closes Avoid
consider-using-f-string
on modulos with brackets in template #8720.Fix a crash when
__all__
exists but cannot be inferred.Closes The undefined variable '__all__' results in an inference failed #8740
Fix crash when a variable is assigned to a class attribute of identical name.
Closes Setting the identical name between an attribute and a variable causes a fatal error #8754
Fixed a crash when calling
copy.copy()
without arguments.Closes no-argument call to copy.copy() crashes #8774
Other Changes
Fix a crash when a
nonlocal
is defined at module-level.Closes Checking incorrect usage of the keyword 'nonlocal' results in fatal errors. #8735