- Update to 3.3.7
* Comparisons between two calls to `type()` won't raise an
``unidiomatic-typecheck`` warning anymore, consistent with
the behavior applied only for ``==`` previously.
* Fixed a crash when importing a class decorator that did not
exist with the same name as a class attribute after the class
definition.
* Fix a crash caused by malformed format strings when using
`.format` with keyword arguments.
* Using a slice as a class decorator now raises a ``not-callable``
message instead of crashing. A lot of checks that dealt with
decorators (too many to list) are now shortcut if the decorator
can't immediately be inferred to a function or class definition.
* The algorithm used for ``no-member`` suggestions is now more
efficient and cuts the calculation when the distance score is
already above the threshold.
OBS-URL: https://build.opensuse.org/request/show/1277663
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pylint?expand=0&rev=171
- Update to 3.3.6:
* Fix a false positive for used-before-assignment when an inner function's
return type * annotation is a class defined at module scope.
* Fix false positives for use-implicit-booleaness-not-comparison,
use-implicit-booleaness-not-comparison-to-string and
use-implicit-booleaness-not-comparison-to-zero when chained comparisons
are checked.
* Fix a false positive for invalid-getnewargs-ex-returned when the tuple or
dict has been assigned to a name.
* Remove getopt and optparse from the list of deprecated modules.
* Fixed conditional import x.y causing false positive
possibly-used-before-assignment.
* Fix a crash when something besides a class is found in an except handler.
* Fixed raising invalid-name when using camelCase for private methods with
two leading underscores.
* Fixes "skipped files" count calculation; the previous method was
displaying an arbitrary number.
* Fixes a crash that occurred when pylint was run in a container on a host
with cgroupsv2 and restrictions on CPU usage.
* Relaxed the requirements for isort so pylint can benefit from isort 6.
* Fix false positives for undefined-variable for classes using Python 3.12
generic type syntax.
* Fix a false positive for use-implicit-booleaness-not-len. No lint should
be emitted for generators (len is not defined for generators).
* Fix Unable to import 'collections.abc' (import-error) on Python 3.13.1.
* Fix a false positive for potential-index-error when an indexed iterable
contains a starred element that evaluates to more than one item.
* Fixes the issue with --source-root option not working when the source
files are in a subdirectory of the source root (e.g. when using a /src
layout).
OBS-URL: https://build.opensuse.org/request/show/1267802
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pylint?expand=0&rev=46
* Fix a false positive for used-before-assignment when an inner function's
return type * annotation is a class defined at module scope.
* Fix false positives for use-implicit-booleaness-not-comparison,
use-implicit-booleaness-not-comparison-to-string and
use-implicit-booleaness-not-comparison-to-zero when chained comparisons
are checked.
* Fix a false positive for invalid-getnewargs-ex-returned when the tuple or
dict has been assigned to a name.
* Remove getopt and optparse from the list of deprecated modules.
* Fixed conditional import x.y causing false positive
possibly-used-before-assignment.
* Fix a crash when something besides a class is found in an except handler.
* Fixed raising invalid-name when using camelCase for private methods with
two leading underscores.
* Fixes "skipped files" count calculation; the previous method was
displaying an arbitrary number.
* Fixes a crash that occurred when pylint was run in a container on a host
with cgroupsv2 and restrictions on CPU usage.
* Relaxed the requirements for isort so pylint can benefit from isort 6.
* Fix false positives for undefined-variable for classes using Python 3.12
generic type syntax.
* Fix a false positive for use-implicit-booleaness-not-len. No lint should
be emitted for generators (len is not defined for generators).
* Fix Unable to import 'collections.abc' (import-error) on Python 3.13.1.
* Fix a false positive for potential-index-error when an indexed iterable
contains a starred element that evaluates to more than one item.
* Fixes the issue with --source-root option not working when the source
files are in a subdirectory of the source root (e.g. when using a /src
layout).
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pylint?expand=0&rev=169
* Fix regression causing some f-strings to not be inferred as
strings.
- update to 3.3.0:
* We migrated ``symilar`` to argparse, from getopt, so the
error and help output changed (for the better).
We exit with 2 instead of sometime 1, sometime 2.
The error output is not captured by the runner anymore.
It's not possible to use a value for the boolean options
anymore (``--ignore-comments 1`` should become
``--ignore-comments``).
* Add new `declare-non-slot` error which reports when a class
has a `__slots__` member and a type hint on the class is not
present in `__slots__`.
* Added `too-many-positional-arguments` to allow distinguishing
the configuration for too many total arguments
(with keyword-only params specified after `*`) from the
configuration for too many positional-or-keyword or
positional-only arguments.
* Add `using-exception-group-in-unsupported-version` and
`using-generic-type-syntax-in-unsupported-version` for uses
of Python 3.11+ or 3.12+ features on lower supported versions
provided with `--py-version`.
* Add `using-assignment-expression-in-unsupported-version` for
uses of `:=` (walrus operator) on Python versions below 3.8
provided with `--py-version`.
* Add `using-positional-only-args-in-unsupported-version` for
uses of positional-only args on Python versions below 3.8
provided with `--py-version`.
* Add ``unnecessary-default-type-args`` to the ``typing``
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pylint?expand=0&rev=163
- Update to 3.2.6:
* Quiet false positives for unexpected-keyword-arg when pylint cannot
determine which of two or more dynamically defined classes is being
instantiated.
* Fix a false positive for missing-param-doc where a method which is
decorated with typing.overload was expected to have a docstring
specifying its parameters.
* Fix a regression that raised invalid-name on class attributes merely
overriding invalid names from an ancestor.
* Treat assert_never() the same way when imported from typing_extensions.
* Fix a false positive for consider-using-min-max-builtin when the
assignment target is an attribute.
* Fix an AssertionError arising from properties that return partial
functions.
* Fix a crash when a subclass extends __slots__.
- Refresh pytest-8.patch.
- Add patch support-astroid-3.3.patch:
* Support astroid >= 3.3.0.
OBS-URL: https://build.opensuse.org/request/show/1193321
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pylint?expand=0&rev=43
* Quiet false positives for unexpected-keyword-arg when pylint cannot
determine which of two or more dynamically defined classes is being
instantiated.
* Fix a false positive for missing-param-doc where a method which is
decorated with typing.overload was expected to have a docstring
specifying its parameters.
* Fix a regression that raised invalid-name on class attributes merely
overriding invalid names from an ancestor.
* Treat assert_never() the same way when imported from typing_extensions.
* Fix a false positive for consider-using-min-max-builtin when the
assignment target is an attribute.
* Fix an AssertionError arising from properties that return partial
functions.
* Fix a crash when a subclass extends __slots__.
- Refresh pytest-8.patch.
- Add patch support-astroid-3.3.patch:
* Support astroid >= 3.3.0.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pylint?expand=0&rev=161
- Add new patch to fix failing tests with pytest 8, pytest-8.patch
gh#pylint-dev/pylint#9576
- Skip some tests that still are failing with pytest 8,
gh#pylint-dev/pylint#9545
- update to 3.2.5:
* Fixed a false positive ``unreachable-code`` when using
``typing.Any`` as return type in python 3.8, the
``typing.NoReturn`` are not taken into account
anymore for python 3.8 however.
* Prevent emitting ``possibly-used-before-assignment`` when
relying on names only potentially not defined in conditional
blocks guarded by functions annotated with ``typing.Never``
or ``typing.NoReturn``.
- update to 3.2.3:
* Classes with only an Ellipsis (``...``) in their body do not
trigger 'multiple-statements' anymore if they are inlined
* Fix a false positive for ``redefined-outer-name`` when there
is a name defined in an exception-handling block which shares
the same name as a local variable that has been defined in a
function body.
* Fix a false positive for ``use-yield-from`` when using the
return value from the ``yield`` atom.
- update to 3.2.2:
* Fix multiple false positives for generic class syntax added
in Python 3.12 (PEP 695).
* Exclude context manager without cleanup from
``contextmanager-generator-missing-cleanup`` checks.
- update to 3.2.1:
* Exclude if/else branches containing terminating functions
(e.g. `sys.exit()`) from `possibly-used-before-assignment`
checks.
* Don't emit ``typevar-name-incorrect-variance`` warnings for
PEP 695 style TypeVars.
* The variance is inferred automatically by the type checker.
* Adding ``_co`` or ``_contra`` suffix can help to reason about
TypeVar.
- update to 3.2.0:
* Understand `six.PY2` and `six.PY3` for conditional imports.
* Github can use to automatically annotate code. Use it with
`pylint --output-format=github` on your Github Workflows.
* Add check ``possibly-used-before-assignment`` when relying on
names after an ``if/else`` switch when one branch failed to
define the name, raise, or return.
* Checks for generators that use contextmanagers that don't
handle cleanup properly.
* Is meant to raise visibilty on the case that a generator is
not fully exhausted and the contextmanager is not cleaned up
properly.
* A contextmanager must yield a non-constant value and not
handle cleanup for GeneratorExit.
* The using generator must attempt to use the yielded context
value `with x() as y` and not just `with x()`.
OBS-URL: https://build.opensuse.org/request/show/1186384
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pylint?expand=0&rev=42
* Fixed a false positive ``unreachable-code`` when using
``typing.Any`` as return type in python 3.8, the
``typing.NoReturn`` are not taken into account
anymore for python 3.8 however.
* Prevent emitting ``possibly-used-before-assignment`` when
relying on names only potentially not defined in conditional
blocks guarded by functions annotated with ``typing.Never``
or ``typing.NoReturn``.
- update to 3.2.3:
* Classes with only an Ellipsis (``...``) in their body do not
trigger 'multiple-statements' anymore if they are inlined
* Fix a false positive for ``redefined-outer-name`` when there
is a name defined in an exception-handling block which shares
the same name as a local variable that has been defined in a
function body.
* Fix a false positive for ``use-yield-from`` when using the
return value from the ``yield`` atom.
- update to 3.2.2:
* Fix multiple false positives for generic class syntax added
in Python 3.12 (PEP 695).
* Exclude context manager without cleanup from
``contextmanager-generator-missing-cleanup`` checks.
- update to 3.2.1:
* Exclude if/else branches containing terminating functions
(e.g. `sys.exit()`) from `possibly-used-before-assignment`
checks.
* Don't emit ``typevar-name-incorrect-variance`` warnings for
PEP 695 style TypeVars.
* The variance is inferred automatically by the type checker.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pylint?expand=0&rev=158
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.