You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Exception on node <Call l.7 at 0x103d11a80> in file '/private/tmp/pydantic/example.py'
Traceback (most recent call last):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint/utils/ast_walker.py", line 91, in walk
callback(astroid)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint/checkers/base/basic_checker.py", line 713, in visit_call
if utils.is_terminating_func(node):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint/checkers/utils.py", line 2197, in is_terminating_func
for inferred in node.func.infer():
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/node_ng.py", line 171, in infer
yield from self._infer(context=context, **kwargs)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/decorators.py", line 143, in raise_if_nothing_inferred
yield next(generator)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/decorators.py", line 112, in wrapped
for res in _func(node, context, **kwargs):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/inference.py", line 358, in infer_attribute
for owner in self.expr.infer(context):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/node_ng.py", line 184, in infer
for i, result in enumerate(self._infer(context=context, **kwargs)):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/decorators.py", line 143, in raise_if_nothing_inferred
yield next(generator)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/decorators.py", line 112, in wrapped
for res in _func(node, context, **kwargs):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/inference.py", line 372, in infer_attribute
yield from owner.igetattr(self.attrname, context)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/scoped_nodes/scoped_nodes.py", line 438, in igetattr
return bases._infer_stmts(self.getattr(name, context), context, frame=self)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/scoped_nodes/scoped_nodes.py", line 414, in getattr
result = [self.import_module(name, relative_only=True)]
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/scoped_nodes/scoped_nodes.py", line 530, in import_module
return AstroidManager().ast_from_module_name(
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 246, in ast_from_module_name
return self.ast_from_file(found_spec.location, modname, fallback=False)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 138, in ast_from_file
return AstroidBuilder(self).file_build(filepath, modname)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 145, in file_build
return self._post_build(module, builder, encoding)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 166, in _post_build
self.add_from_names_to_locals(from_node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 223, in add_from_names_to_locals
imported = node.do_import_module()
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/_base_nodes.py", line 146, in do_import_module
return mymodule.import_module(
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/scoped_nodes/scoped_nodes.py", line 530, in import_module
return AstroidManager().ast_from_module_name(
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 246, in ast_from_module_name
return self.ast_from_file(found_spec.location, modname, fallback=False)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 138, in ast_from_file
return AstroidBuilder(self).file_build(filepath, modname)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 145, in file_build
return self._post_build(module, builder, encoding)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 166, in _post_build
self.add_from_names_to_locals(from_node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 223, in add_from_names_to_locals
imported = node.do_import_module()
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/_base_nodes.py", line 146, in do_import_module
return mymodule.import_module(
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/nodes/scoped_nodes/scoped_nodes.py", line 530, in import_module
return AstroidManager().ast_from_module_name(
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 246, in ast_from_module_name
return self.ast_from_file(found_spec.location, modname, fallback=False)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 138, in ast_from_file
return AstroidBuilder(self).file_build(filepath, modname)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 145, in file_build
return self._post_build(module, builder, encoding)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/builder.py", line 173, in _post_build
module = self._manager.visit_transforms(module)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/manager.py", line 109, in visit_transforms
return self._transform.visit(node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 89, in visit
return self._visit(module)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 54, in _visit
visited = self._visit_generic(value)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 61, in _visit_generic
return [self._visit_generic(child) for child in node]
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 61, in <listcomp>
return [self._visit_generic(child) for child in node]
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 67, in _visit_generic
return self._visit(node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 54, in _visit
visited = self._visit_generic(value)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 61, in _visit_generic
return [self._visit_generic(child) for child in node]
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 61, in <listcomp>
return [self._visit_generic(child) for child in node]
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 67, in _visit_generic
return self._visit(node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 57, in _visit
return self._transform(node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/astroid/transforms.py", line 39, in _transform
ret = transform_func(node)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint_pydantic/__init__.py", line 53, in transform
if _is_classmethod_decorator(node):
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint_pydantic/__init__.py", line 42, in _is_classmethod_decorator
decorator_name = _get_decorator_name(decorator)
File "/private/tmp/pydantic/venv2/lib/python3.10/site-packages/pylint_pydantic/__init__.py", line 33, in _get_decorator_name
raise ValueError("Invalid decorator name")
ValueError: Invalid decorator name
************* Module example
example.py:1:0: F0002: example.py: Fatal error while checking 'example.py'. Please open an issue in our bug tracker so we address this. There is a pre-filled template that you can use in '.......txt'. (astroid-error)
-----------------------------------
Your code has been rated at 0.00/10
Specifications like the version of the project, operating system, or hardware
Problem description
Running pylint with pylint-pydantic==0.2.2 and scipy==1.11.1 may cause ValueError: Invalid decorator name.
Steps to reproduce the problem
Save to example.py:
create a clean virtualenv and install (currently, the most recent versions):
and run:
Result:
Specifications like the version of the project, operating system, or hardware
The text was updated successfully, but these errors were encountered: