Skip to content
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

Issues with Run By Line #11740

Closed
1 of 2 tasks
olguzzar opened this issue Oct 21, 2022 · 3 comments
Closed
1 of 2 tasks

Issues with Run By Line #11740

olguzzar opened this issue Oct 21, 2022 · 3 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug notebook-run-by-line

Comments

@olguzzar
Copy link

olguzzar commented Oct 21, 2022

Applies To

  • Notebooks (.ipynb files)
  • Interactive Window and/or Cell Scripts (.py files with #%% markers)

What happened?

  1. When running a cell via the Run By Line option, after running each line by continually clicking "run next line" until I got to the end of the cell, a green check mark appeared indicating the cell run was done. However, the "Continue Execution" option was still available, and I was not able to view the "debug cell" dropdown to the left of a cell until I clicked "continue execution". Recording is here, starting at 28:15. I was able to repro several times over the course of about 5 minutes
  2. Not sure if this is just a fluke or related to the above issue, because I only experienced this while running this recording, and have never experienced it in another notebook run: while running by line a cell that calls a method in another cell, and that original cell has a breakpoint in it, the run by line just spins and spins and does not run the cell. Specific point in the recording begins at 31:00

VS Code Version

Version: 1.72.2 (user setup) Commit: d045a5eda657f4d7b676dedbfa7aab8207f8a075 Date: 2022-10-12T22:15:18.074Z Electron: 19.0.17 Chromium: 102.0.5005.167 Node.js: 16.14.2 V8: 10.2.154.15-electron.0 OS: Windows_NT x64 10.0.22621 Sandboxed: No

Jupyter Extension Version

v2022.9.1202862440

Jupyter logs

error 14:53:50.698: Jupyter Extension (Error in requestVariables, method:requestVariables): Canceled: Canceled
    at c.handleErrorResponse (vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:47042)
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:46933
error 14:53:50.729: Jupyter Extension (Error in requestVariables, method:requestVariables): Error [CodeExpectedError]: custom request failed
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1725:7640
    at process.processTicksAndRejections (node:internal/process/task_queues:96:5)
error 14:53:56.483: Jupyter Extension (Error in requestVariables, method:requestVariables): Error [CodeExpectedError]: Thread id: pid_32940_id_2661408800264 is not current thread id.
    at c.handleErrorResponse (vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:47505)
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:46933
error 14:53:58.379: Jupyter Extension (Error in requestVariables, method:requestVariables): Error [CodeExpectedError]: Thread id: pid_32940_id_2661408800264 is not current thread id.
    at c.handleErrorResponse (vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:47505)
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:46933
error 14:53:58.460: Jupyter Extension (Error in requestVariables, method:requestVariables): Error [CodeExpectedError]: Unable to find thread for evaluation.
    at c.handleErrorResponse (vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:47505)
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:46933
error 14:54:01.701: Jupyter Extension (Error in requestVariables, method:requestVariables): Error [CodeExpectedError]: Thread id: pid_32940_id_2661408800264 is not current thread id.
    at c.handleErrorResponse (vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:47505)
    at vscode-file://vscode-app/c:/Users/olguzzar/AppData/Local/Programs/Microsoft%20VS%20Code/resources/app/out/vs/workbench/workbench.desktop.main.js:1056:46933
warn 14:54:01.727: StdErr from Kernel Process [IPKernelApp] ERROR | Exception in control handler:
Traceback (most recent call last):
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\kernelbase.py", line 334, in process_control
    await result
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\kernelbase.py", line 953, in debug_request
    reply_content = await reply_content
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\ipkernel.py", line 466, in do_debug_request
    return await self.debugger.process_request(msg)
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\debugger.py", line 665, in process_request
    self.stop()
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\debugger.py", line 408, in stop
    self.debugpy_client.disconnect_tcp_socket()
  File "c:\Users\olguzzar\Anaconda3\envs\golden_scenario_env2\lib\site-packages\ipykernel\debugger.py", line 254, in disconnect_tcp_socket
    self.debugpy_stream.socket.disconnect(self._get_endpoint())
  File "zmq/backend/cython/socket.pyx", line 668, in zmq.backend.cython.socket.Socket.disconnect
zmq.error.ZMQError: No such file or directory

Coding Language and Runtime Version

No response

Language Extension Version (if applicable)

No response

Anaconda Version (if applicable)

2022.05

Running Jupyter locally or remotely?

Local

@olguzzar olguzzar added the bug Issue identified by VS Code Team member as probable bug label Oct 21, 2022
@amunger amunger assigned roblourens and unassigned amunger Oct 21, 2022
@roblourens
Copy link
Member

Thanks @olguzzar, it seems like I don't have permission to view that video though

@olguzzar
Copy link
Author

olguzzar commented Oct 24, 2022

Sorry about that! The permissions issue should be fixed, but here's the uploaded video clip with the relevant repro just in case

Run.By.Line.Repro.mp4

@roblourens
Copy link
Member

Thanks! I think this is probably the same issue that we are getting from microsoft/debugpy#1051. We should run the golden scenario with verbose logging enabled though which would tell me if it's actually something else. I will add that setting to the golden scenario script.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug notebook-run-by-line
Projects
None yet
Development

No branches or pull requests

3 participants