Commit d66be90f authored by Jason Madden's avatar Jason Madden

Workaround pylint bug:

Exception on node <FunctionDef.python_check_callback l.58 at 0x12615c910> in file '/src/gevent/libev/corecffi.py'
Traceback (most recent call last):
  File "///bin/pylint", line 8, in <module>
    sys.exit(run_pylint())
  File "///lib/python3.9/site-packages/pylint/__init__.py", line 24, in run_pylint
    PylintRun(sys.argv[1:])
  File "///lib/python3.9/site-packages/pylint/lint/run.py", line 384, in __init__
    linter.check(args)
  File "///lib/python3.9/site-packages/pylint/lint/pylinter.py", line 973, in check
    self._check_files(
  File "///lib/python3.9/site-packages/pylint/lint/pylinter.py", line 1007, in _check_files
    self._check_file(get_ast, check_astroid_module, name, filepath, modname)
  File "///lib/python3.9/site-packages/pylint/lint/pylinter.py", line 1033, in _check_file
    check_astroid_module(ast_node)
  File "///lib/python3.9/site-packages/pylint/lint/pylinter.py", line 1170, in check_astroid_module
    retval = self._check_astroid_module(
  File "///lib/python3.9/site-packages/pylint/lint/pylinter.py", line 1215, in _check_astroid_module
    walker.walk(ast_node)
  File "///lib/python3.9/site-packages/pylint/utils/ast_walker.py", line 77, in walk
    self.walk(child)
  File "///lib/python3.9/site-packages/pylint/utils/ast_walker.py", line 77, in walk
    self.walk(child)
  File "///lib/python3.9/site-packages/pylint/utils/ast_walker.py", line 74, in walk
    callback(astroid)
  File "///lib/python3.9/site-packages/pylint/checkers/classes.py", line 1070, in visit_functiondef
    self._check_signature(node, parent_function, "overridden", klass)
  File "///lib/python3.9/site-packages/pylint/checkers/classes.py", line 1930, in _check_signature
    + f"was {total_args_refmethod} in '{refmethod.parent.name}.{refmethod.name}' and "
AttributeError: 'If' object has no attribute 'name'

pylint 2.9.3, astroid 2.6.2
parent 2832922f
......@@ -55,7 +55,7 @@ from gevent._ffi.loop import assign_standard_callbacks
class _Callbacks(AbstractCallbacks):
# pylint:disable=arguments-differ,arguments-renamed
def python_check_callback(self, _loop, watcher_ptr, _events):
def python_check_callback(self, *args):
pass
def python_prepare_callback(self, _loop_ptr, watcher_ptr, _events):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment