Bug description
I created a python class EntryExit that implements enter(...) and exit(...).
when I use
with EntryExit() as e_e:
I would assume that the variable e_e is instantiated, but that does not happen, e_e remains None
pylint crashes on this code
python causes an AttributeError
see also the uploaded file
Configuration
No response
Command used
Pylint output
Exception on node <Call l.44 at 0x1fd8c99fc80> in file 'C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\tester.py'
Traceback (most recent call last):
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\astroid\decorators.py", line 143, in raise_if_nothing_inferred
yield next(generator)
^^^^^^^^^^^^^^^
StopIteration
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\pylint\utils\ast_walker.py", line 91, in walk
callback(astroid)
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\pylint\checkers\base\basic_checker.py", line 713, in visit_call
if utils.is_terminating_func(node):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\pylint\checkers\utils.py", line 2202, in is_terminating_func
return True
^^^^
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\astroid\nodes\node_ng.py", line 171, in infer
yield from self._infer(context=context, **kwargs)
File "C:\Users\hsalo\source\repos\Buku Pintar\2020\Python_312\tester\venv\Lib\site-packages\astroid\decorators.py", line 149, in raise_if_nothing_inferred
raise InferenceError(
astroid.exceptions.InferenceError: StopIteration raised without any error information.
Expected behavior
something about unsupported code or that the variable is None
Pylint version
python 3.12 (also on version 3.11)
OS / Environment
Windows, using Pycharm 2023.1.1
Additional dependencies
none
pylint-crash-2023-05-17-14-01-33.txt
Bug description
I created a python class EntryExit that implements enter(...) and exit(...).
when I use
with EntryExit() as e_e:
I would assume that the variable e_e is instantiated, but that does not happen, e_e remains None
pylint crashes on this code
python causes an AttributeError
see also the uploaded file
Configuration
No response
Command used
Pylint output
Expected behavior
something about unsupported code or that the variable is None
Pylint version
OS / Environment
Windows, using Pycharm 2023.1.1
Additional dependencies
none
pylint-crash-2023-05-17-14-01-33.txt