-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception: 'NoneType' object has no attribute 'additional_info' #492
Comments
I also found that Python interpreter is probably set up wrong and can't fix it. Please see the screenshot below. If I set up "justMyCode": false in launch.json, I immediately hit some exceptions in Python installed somewhere else (no in env). My settings:
But when I click the select interpreter it pretends it doesn't recognize it: |
Have you tried putting the full path in As for the i.e.:
|
@fabioz Thanks for your response. Yes, I tried. The same result. |
As a note, I'm waiting for the logs... or at least the full stack trace (as it is, I just know that So, given that this report is currently not actionable and further info wasn't provided, I'm going to close the request. @KathRains Please reopen when/if you're able to provide the logs. |
Hi, sorry for the delay, here are logs, in zip file. Please remove them out from the git after you download them if possible because they may have some sensitive information (even although I checked and cleaned files). Thanks. I don't know how to reopen the issue though (I think it's not possible for me because I didn't close it). |
Thanks for the info. I've just reopened the issue. |
Can you do one check for me? In the file:
In line 919 (inside the if you add
Does it stop giving that error? |
Let me try |
Okay, it looks like the exception has gone after I added that line. At least, I don't see any information in the terminal. |
This reverts commit 4fe9c15.
Environment data
python.languageServer
setting: -Expected behaviour
Works normally
Actual behaviour
Hit the exception: NoneType' object has no attribute 'additional_info'
.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd_pydevd_bundle\pydevd_additional_thread_info_regular.py", line 125
Steps to reproduce:
Not sure how to repro it. It suddenly stopped working. What I did - I added the line into the code that should throw an exception, and created handlers that would catch it but they don't. Instead, if I debug the code, I have that exception.
Logs
User belongs to experiment group 'ShowPlayIcon - start' User belongs to experiment group 'ShowExtensionSurveyPrompt - enabled' User belongs to experiment group 'DebugAdapterFactory - experiment' User belongs to experiment group 'PtvsdWheels37 - experiment' User belongs to experiment group 'UseTerminalToGetActivatedEnvVars - control' User belongs to experiment group 'LocalZMQKernel - experiment' User belongs to experiment group 'CollectLSRequestTiming - control' User belongs to experiment group 'CollectNodeLSRequestTiming - experiment' User belongs to experiment group 'EnableIPyWidgets - experiment' User belongs to experiment group 'RunByLine - experiment' User belongs to experiment group 'CustomEditorSupport - control' User belongs to experiment group 'pythonaa' User belongs to experiment group 'pythonInstallPylintButtonFirstcf' Error 2020-12-07 15:30:24: Failed to create File hash for interpreter D:\Python332\python.exe [Error: ENOENT: no such file or directory, lstat 'D:\Python332\python.exe'] { errno: -4058, code: 'ENOENT', syscall: 'lstat', path: 'D:\\Python332\\python.exe' } > pyenv root > conda --version > python3.7 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > python3.6 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > python3 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > python c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > py -3.6 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > py -3 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > py -3.7 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > py -2 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > d:\Projects\Work\test\test-backend\venv\Scripts\python.exe c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" > python2 c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py -c "import sys;print(sys.executable)" Python interpreter path: .\venv\Scripts\python.exe Starting Jedi Python language engine. > C:\Development\Anaconda3\Scripts\conda.exe info --json > C:\Development\Anaconda3\Scripts\conda.exe env list Error 2020-12-07 15:30:29: Failed to get interpreter information for 'D:\Python332\python.exe' [Error: Command failed: "D:\\Python332\python.exe" "c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py" "c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\interpreterInfo.py" The system cannot find the path specified.
Traceback (most recent call last): File "c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy\_vendored\pydevd\_pydevd_bundle\pydevd_additional_thread_info_regular.py", line 115, in set_additional_thread_info additional_info = thread.additional_info AttributeError: 'NoneType' object has no attribute 'additional_info'killed: false,
code: 1,
signal: null,
cmd: '"D:\\Python332\python.exe" "c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\pyvsc-run-isolated.py" "c:\Users\user\.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\interpreterInfo.py"'
}
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd_pydevd_bundle\pydevd_frame.py", line 1022, in trace_dispatch
self.do_wait_suspend(thread, frame, event, arg)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd_pydevd_bundle\pydevd_frame.py", line 153, in do_wait_suspend
self._args[0].do_wait_suspend(*args, **kwargs)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd\pydevd.py", line 1854, in do_wait_suspend
with self._threads_suspended_single_notification.notify_thread_suspended(thread_id, stop_reason):
File "C:\Development\Python36\lib\contextlib.py", line 81, in enter
return next(self.gen)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd\pydevd.py", line 422, in notify_thread_suspended
with AbstractSingleNotificationBehavior.notify_thread_suspended(self, thread_id, stop_reason):
File "C:\Development\Python36\lib\contextlib.py", line 81, in enter
return next(self.gen)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd\pydevd.py", line 376, in notify_thread_suspended
self.on_thread_suspend(thread_id, stop_reason)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd\pydevd.py", line 347, in on_thread_suspend
self.send_suspend_notification(thread_id, stop_reason)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd\pydevd.py", line 416, in send_suspend_notification
py_db.writer.add_command(py_db.cmd_factory.make_thread_suspend_single_notification(py_db, thread_id, stop_reason))
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd_pydevd_bundle\pydevd_net_command_factory_json.py", line 315, in make_thread_suspend_single_notification
info = set_additional_thread_info(thread)
File "c:\Users\user.vscode\extensions\ms-python.python-2020.11.371526539\pythonFiles\lib\python\debugpy_vendored\pydevd_pydevd_bundle\pydevd_additional_thread_info_regular.py", line 125, in set_additional_thread_info
thread.additional_info = additional_info
AttributeError: 'NoneType' object has no attribute 'additional_info'
The text was updated successfully, but these errors were encountered: