pylint 3.0 deprectations
Changelog: https://pylint.pycqa.org/en/latest/whatsnew/3/3.0/index.html#summary-release-highlights remove `__implements__`: That attribute is apparently from a rejected PEP. They say to inherit from BaseChecker, which we are already doing. https://github.com/pylint-dev/pylint/pull/8404 check_messages -> only_required_for_messages: Seems straightforward instructions. I haven't actually tested it. https://github.com/pylint-dev/pylint/pull/8409 remove emptystring extension: Looks like this has been replaced by https://pylint.readthedocs.io/en/stable/user_guide/messages/convention/use-implicit-booleaness-not-comparison-to-string.html Which is disabled by default but we have `enable=ALL`, so I guess that means we indeed have it enabled. And update changelog URLs.
This commit is contained in:
parent
2c503bf35d
commit
750e2b0a72
|
|
@ -3,7 +3,6 @@ ignore=resources.py
|
|||
extension-pkg-whitelist=PyQt5,PyQt6,sip
|
||||
load-plugins=qute_pylint.config,
|
||||
pylint.extensions.docstyle,
|
||||
pylint.extensions.emptystring,
|
||||
pylint.extensions.overlapping_exceptions,
|
||||
pylint.extensions.code_style,
|
||||
pylint.extensions.comparison_placement,
|
||||
|
|
|
|||
|
|
@ -1,9 +1,8 @@
|
|||
{
|
||||
"pylint": "https://pylint.pycqa.org/en/latest/whatsnew/2/index.html",
|
||||
"pylint": "https://pylint.pycqa.org/en/latest/whatsnew/3/index.html",
|
||||
"tomlkit": "https://github.com/sdispater/tomlkit/blob/master/CHANGELOG.md",
|
||||
"dill": "https://github.com/uqfoundation/dill/commits/master",
|
||||
"isort": "https://github.com/PyCQA/isort/blob/main/CHANGELOG.md",
|
||||
"lazy-object-proxy": "https://github.com/ionelmc/python-lazy-object-proxy/blob/master/CHANGELOG.rst",
|
||||
"mccabe": "https://github.com/PyCQA/mccabe#changes",
|
||||
"pytest-cov": "https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst",
|
||||
"pytest-xdist": "https://github.com/pytest-dev/pytest-xdist/blob/master/CHANGELOG.rst",
|
||||
|
|
@ -93,7 +92,6 @@
|
|||
"altgraph": "https://github.com/ronaldoussoren/altgraph/blob/master/doc/changelog.rst",
|
||||
"urllib3": "https://github.com/urllib3/urllib3/blob/main/CHANGES.rst",
|
||||
"lxml": "https://github.com/lxml/lxml/blob/master/CHANGES.txt",
|
||||
"wrapt": "https://github.com/GrahamDumpleton/wrapt/blob/develop/docs/changes.rst",
|
||||
"cryptography": "https://cryptography.io/en/latest/changelog.html",
|
||||
"toml": "https://github.com/uiri/toml/releases",
|
||||
"tomli": "https://github.com/hukkin/tomli/blob/master/CHANGELOG.md",
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ class ConfigChecker(checkers.BaseChecker):
|
|||
|
||||
"""Custom astroid checker for config calls."""
|
||||
|
||||
__implements__ = interfaces.IAstroidChecker
|
||||
name = 'config'
|
||||
msgs = {
|
||||
'E9998': ('%s is no valid config option.', # flake8: disable=S001
|
||||
|
|
@ -31,7 +30,7 @@ class ConfigChecker(checkers.BaseChecker):
|
|||
priority = -1
|
||||
printed_warning = False
|
||||
|
||||
@utils.check_messages('bad-config-option')
|
||||
@utils.only_required_for_messages('bad-config-option')
|
||||
def visit_attribute(self, node):
|
||||
"""Visit a getattr node."""
|
||||
# We're only interested in the end of a config.val.foo.bar chain
|
||||
|
|
|
|||
Loading…
Reference in New Issue