Skip to content

Python Uncaught Error 2024.2.1 #23554

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

Closed
dokutoshi opened this issue Jun 4, 2024 · 5 comments
Closed

Python Uncaught Error 2024.2.1 #23554

dokutoshi opened this issue Jun 4, 2024 · 5 comments
Assignees
Labels
triage-needed Needs assignment to the proper sub-team

Comments

@dokutoshi
Copy link

Type: Bug

Profile extension states 1 uncaught errors

Extension version: 2024.2.1
VS Code version: Code 1.84.2 (1a5daa3a0231a0fbba4f14db7ec463cf99d7768e, 2023-11-09T10:52:57.054Z)
OS version: Darwin arm64 23.3.0
Modes:
Connection to 'ssh-remote+7b22686f73744e616d65223a22444c5f4f43525f4c656f5f50335f5562756e74755f4e65775f4d61696e227d' could not be established
Remote OS version: Linux x64 4.14.301-224.520.amzn2.x86_64

System Info
Item Value
CPUs Apple M1 (8 x 24)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled
Load (avg) 2, 2, 2
Memory (System) 16.00GB (1.01GB free)
Process Argv --crash-reporter-id c34a5dda-8d8c-4391-ab65-442321cfa1cb
Screen Reader no
VM 0%

Connection to 'ssh-remote+7b22686f73744e616d65223a22444c5f4f43525f4c656f5f50335f5562756e74755f4e65775f4d61696e227d' could not be established

Item Value
Remote SSH: DL_OCR_Leo_P3_Main_Adam
OS Linux x64 4.14.301-224.520.amzn2.x86_64
CPUs Intel(R) Xeon(R) CPU E5-2686 v4 @ 2.30GHz (8 x 2700)
Memory (System) 59.96GB (42.49GB free)
VM 0%
A/B Experiments
vsliv368:30146709
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscorecescf:30445987
vscod805cf:30301675
binariesv615:30325510
vsaa593:30376534
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
a9j8j154:30646983
962ge761:30959799
pythongtdpath:30769146
welcomedialogc:30910334
pythonidxpt:30866567
pythonnoceb:30805159
asynctok:30898717
pythontestfixt:30902429
pythonregdiag2:30936856
pythonmypyd1:30879173
pythoncet0:30885854
pythontbext0:30879054
accentitlementsc:30995553
dsvsc016:30899300
dsvsc017:30899301
dsvsc018:30899302
cppperfnew:31000557
dsvsc020:30976470
pythonait:31006305
jchc7451:31067544
chatpanelt:31048053
dsvsc021:30996838
bdiig495:31013172
a69g1124:31058053
dvdeprecation:31061160
pythonprt:31056678
dwnewjupyter:31046869
26j00206:31048877

@karthiknadig
Copy link
Member

@dokutoshi Can you share the error stack if this occurs again? either from logs or you should be able to see it from the developer console (Help > toggle Developer tools)

@github-actions github-actions bot added the info-needed Issue requires more information from poster label Jun 12, 2024
@dokutoshi
Copy link
Author

dokutoshi commented Jun 13, 2024

Gladly...

Here is the Window output - somehow related to Discovering Python Interpreters that scans both the remote Mac and Linux servers.

Once the user selects an interpreter either from the notebook or Command Palette: Select Interpreter, the Discovering Python Interpreters commences and never ceases. It can run for hours, literally. @karthiknadig

Remote SSH tends to drop the service juxtaposed Remote Tunnels.


2024-06-13 10:46:16.376 [error] [remote-connection][ExtensionHost][35d13…][reconnect][WebSocket(127.0.0.1:63060)] received error control message when negotiating connection. Error:
2024-06-13 10:46:16.376 [error] Error: Connection error: Unknown reconnection token (seen before)
    at H (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:19292)
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:10586)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at r.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:14848)
    at d.z (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:18026)
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:17358)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at c.acceptChunk (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:12594)
    at vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:11864
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:5135)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at j.onload (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:3364)
2024-06-13 10:46:16.377 [error] [remote-connection][ExtensionHost][35d13…][reconnect] A permanent error occurred in the reconnecting loop! Will give up now! Error:
2024-06-13 10:46:16.377 [error] Error: Connection error: Unknown reconnection token (seen before)
    at H (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:19292)
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:10586)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at r.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:14848)
    at d.z (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:18026)
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:17358)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at c.acceptChunk (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:12594)
    at vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:615:11864
    at u.value (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:5135)
    at h.y (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:659)
    at h.fire (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:89:876)
    at j.onload (vscode-file://vscode-app/Applications/Visual%20Studio%20Code.app/Contents/Resources/app/out/vs/workbench/workbench.desktop.main.js:689:3364)
2024-06-13 10:46:16.406 [error] Extension host (Remote) terminated unexpectedly with code null.
2024-06-13 10:46:16.406 [error] Extension host (Remote) terminated unexpectedly. The following extensions were running: vscode.ipynb, vscode.emmet, vscode.git-base, vscode.git, vscode.github, ms-toolsai.datawrangler, ms-toolsai.jupyter, ms-toolsai.vscode-jupyter-cell-tags, ms-python.python, ms-toolsai.jupyter-renderers, ms-toolsai.vscode-jupyter-powertoys, VisualStudioExptTeam.intellicode-api-usage-examples, VisualStudioExptTeam.vscodeintellicode, ms-python.black-formatter, ms-python.debugpy, ms-python.mypy-type-checker, ms-python.vscode-pylance, ms-toolsai.tensorboard, vscode.tunnel-forwarding, vscode.debug-auto-launch, vscode.merge-conflict

@github-actions github-actions bot removed the info-needed Issue requires more information from poster label Jun 13, 2024
@karthiknadig
Copy link
Member

In the python logs with log level set to trace enabled so you see anything particular it blocks on?

Another thing to try, if you haven't already is to run this command "Python: Clear Cache and reload". That should remove any paths that the extension is holding on to, and hopefully unblocks whatever is causing discovery to wait forever.

FYI: We are actually working on replacing the entire discovery stack using https://github.com/microsoft/python-environment-tools which runs significantly faster and should resolve this issue.

@github-actions github-actions bot added the info-needed Issue requires more information from poster label Jun 13, 2024
Copy link

Because we have not heard back with the information we requested, we are closing this issue for now. If you are able to provide the info later on, then we will be happy to re-open this issue to pick up where we left off.

Happy Coding!

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jul 16, 2024
@dokutoshi
Copy link
Author

In the python logs with log level set to trace enabled so you see anything particular it blocks on?

Another thing to try, if you haven't already is to run this command "Python: Clear Cache and reload". That should remove any paths that the extension is holding on to, and hopefully unblocks whatever is causing discovery to wait forever.

FYI: We are actually working on replacing the entire discovery stack using https://github.com/microsoft/python-environment-tools which runs significantly faster and should resolve this issue.

Clearing the cache with each reload is standard practice.

One important test scenario:

@karthiknadig @DonJayamanne

I extended the workspace using "Add Folder to Workspace" to include a functional folder for TensorFlow.

For clarification:

  • The first folder contains Python source files and a notebook (a static folder).

  • The second folder (the TensorFlow folder) contains logs and metadata files generated by TensorFlow during training, typically per epoch, to save model weights and biases (a dynamic folder). PyTorch has a similar on-training file creation.

Post-observations after including a dynamic folder show that the growth in file count (less than 10 files) during an active kernel leads to a kernel halt. This is different, in my opinion, from including a large data directory with millions of images. In the dynamic folder case, behavior suggests that files added/created in an active workspace trigger the Python discovery process, interrupting an active kernel.

Best,

Leo

@github-actions github-actions bot removed the info-needed Issue requires more information from poster label Jul 16, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 16, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
triage-needed Needs assignment to the proper sub-team
Projects
None yet
Development

No branches or pull requests

2 participants