Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Debugger not pausing in VS Code Unit tests #78

Closed
DonJayamanne opened this issue Feb 15, 2018 · 1 comment
Closed

Debugger not pausing in VS Code Unit tests #78

DonJayamanne opened this issue Feb 15, 2018 · 1 comment
Assignees
Milestone

Comments

@DonJayamanne
Copy link
Contributor

Pausing works in the VS Code UI, however not when running the unit tests
The disconnect request is sent by the test adapter after waiting 5 minutes for the stop event.
As you can see the stop event is not sent back.

  • Here's a log of all the communication (from ipcjson.py)
Input
{"type":"request","seq":1,"command":"initialize","arguments":{"adapterID":"pythonExperimental","linesStartAt1":true,"columnsStartAt1":true,"pathFormat":"path"}}
Output
b'{"type": "response", "seq": 0, "request_seq": 1, "success": true, "command": "initialize", "message": "", "body": {"supportsExceptionInfoRequest": true, "supportsConfigurationDoneRequest": true, "supportsConditionalBreakpoints": true, "supportsSetVariable": true, "supportsExceptionOptions": true, "exceptionBreakpointFilters": [{"filter": "raised", "label": "Raised Exceptions", "default": "true"}, {"filter": "uncaught", "label": "Uncaught Exceptions", "default": "true"}]}}'
Output
b'{"type": "event", "seq": 1, "event": "initialized", "body": {}}'
Input
{"type":"request","seq":3,"command":"configurationDone"}
Output
b'{"type": "response", "seq": 2, "request_seq": 3, "success": true, "command": "configurationDone", "message": "", "body": {}}'
Input
{"type":"request","seq":4,"command":"threads"}
Output
b'{"type": "response", "seq": 3, "request_seq": 4, "success": true, "command": "threads", "message": "", "body": {"threads": [{"id": 1, "name": "MainThread"}]}}'
Input
{"type":"request","seq":5,"command":"pause","arguments":{"threadId":1}}
Output
b'{"type": "response", "seq": 4, "request_seq": 5, "success": true, "command": "pause", "message": "", "body": {}}'
Input
{"type":"request","seq":6,"command":"disconnect"}
Output
b'{"type": "response", "seq": 5, "request_seq": 6, "success": true, "command": "disconnect", "message": "", "body": {}}'
Output
b'{"type": "event", "seq": 6, "event": "exited", "body": {"exitCode": 0}}'
Output
b'{"type": "event", "seq": 7, "event": "terminated", "body": {}}'
@brettcannon
Copy link
Member

Considering this a release blocker for PVSC.

@int19h int19h added this to the Preview 1 milestone Feb 21, 2018
@int19h int19h self-assigned this Feb 28, 2018
int19h added a commit to int19h/vscode-python that referenced this issue Mar 6, 2018
Wait for `process` event before requesting pause.

Increase timeouts when waiting for `process` and `thread`, due to pydevd delay in thread reporting.
int19h added a commit that referenced this issue Mar 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants