Open dlaflamme opened 3 weeks ago
What's your version of the Python extension? This might be a dupe of this issue: https://github.com/microsoft/pylance-release/issues/6178
which required an update to the Python extension.
This is the commit in the Python extension that fixed the problem: https://github.com/microsoft/vscode-python/commit/3641652cca5622839f196c2dc13d5648b8fc8a21
Will check this, thanks.
OK, we updated to the following:
ms-python.python-2024.12.3
ms-python.vscode-pylance-2024.8.2
Can you confirm these have the fix that you mentioned above? It was unclear to me if they did.
And we're still getting an error that looks similar to the originally reported one. The small piece of additional information is that it seems to happen "after a while" and is triggered when the user has 2 interactive windows open (each connected to a different kernel), and the switches between them.
2024-08-30 10:22:13.138 [info] Error: Debug Failure. False expression: Chained file path untitled:/Interactive-3.interactive.py#pylancePrefixCell doesn't match cellFilePaths undefined
at _0x4c4f8d (/local/home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.8.2/dist/server.bundle.js:1:1073408)
at _0xc0b312 (/local/home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.8.2/dist/server.bundle.js:1:1077607)
at _0x508620 (/local/home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.8.2/dist/server.bundle.js:1:1078049)
at /local/home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.8.2/dist/server.bundle.js:1:1004156
2024-08-30 10:22:13.459 [info] [Error - 10:22:13 AM] Server process exited with code 1.
2024-08-30 10:22:13.461 [info] [Error - 10:22:13 AM] Pylance has crashed 5 times in the last 3 minutes. Pylance will not be restarted. Please check [this link](https://aka.ms/AApf7ox) for more details.
With regards to trace logging, we have "python.analysis.logLevel": "Trace",
set in the user's settings.json
file, but I don't see TRACE
-level logging in on the in the python plugin logs so I am not sure it is being set. Additionally, when I look at ~/.vscode-server/data/Machine/settings.json
that file is empty. Let me know if there is a better way to confirm the log level is being set.
looks like we have some issue with interactive window. I have another report on it - https://github.com/microsoft/pylance-release/issues/6312 - that probably due to crash as well.
Let me know if there is anything else I could provide to help.
Environment data
Additionally, in this case VS Code is running on a Windows client and the Remote-SSH extension is being used to access python code on the Linux server.
Code Snippet
There is not a specific code snippet that will trigger this. Instead, see the repro steps. he issue seems to be triggered by using the setup described in the repro steps for some period of time.
Repro Steps
Run a Jupyter notebook outside of VS Code. Do some development in it. In VS Code, start a Jupyter interactive session. "Select Another Kernel", then "Existing Jupyter Server", then select the the kernel running in the Jupyter notebook running outside of VS Code. Test it. (for example, set a variable value on one side and make sure you can see it on the other).
Do regular development in the notebook and run things in the interactive session to examine variables set in the Jupyter kernel.
Eventually pylance will crash. The crashing seems to have increased in frequency in more recent versions of Pylance. I have downgraded to 2024.6.1 and the frequency of occurrence had decreased (but has not been eliminated).
Logs
The above shows representative output. There are more lines like above but they are all of the same flavor as you see above.
Then, the last line in that sequence:
Then several blank lines that just look like the following (a log header with no content)
and finally:
Additionally, I have tried setting
"python.analysis.logLevel": "Trace"
(on VS Code GUI side that is running on windows--but I don't see trace level logs in the output on the Linux host, so not sure if I did that right.