Given one breakpoint is already set and the debugging session has already started, when I browse through the call stack to a different file and use F9 (with g:vimspector_enable_mappings = 'HUMAN'), my first breakpoint is moved to the current file so that I have two breakpoints in the current file instead of two breakpoints in two files as long as I call vimspector#ListBreakpoints() from within the debugging tab
Minimal reproduciton
Does your issue reproduce using vim -Nu /path/to/vimspector/support/minimal_vimrc ? [Yes]
If you are using Neovim, does your issue reproduce using Vim? [Ii'm using vim only]
List of steps to reproduce:
Run vim -Nu /path/to/vimspector/support/minimal_vimrc
I expected to see the two correct breakpoints when running call vimspector#ListBreakpoints() from the debugging tab
Actual behaviour
I see the two incorrect breakpoints when running call vimspector#ListBreakpoints() from the debugging tab, yet when I run this after running call vimspector#Reset(), the breakpoints are correct. If I launch another debugging session, the two breakpoints shown in the quicklist will be incorrect again
Operating system: Windows10 version 1903 (I prefer creating an issue in case this is reproducible on linux. It doesn't hurt either having a trace before trying to go for a PR)
Describe the bug
Given one breakpoint is already set and the debugging session has already started, when I browse through the call stack to a different file and use F9 (with g:vimspector_enable_mappings = 'HUMAN'), my first breakpoint is moved to the current file so that I have two breakpoints in the current file instead of two breakpoints in two files as long as I call
vimspector#ListBreakpoints()
from within the debugging tabMinimal reproduciton
vim -Nu /path/to/vimspector/support/minimal_vimrc
? [Yes]List of steps to reproduce:
vim -Nu /path/to/vimspector/support/minimal_vimrc
/entities/Message.cs
dotnet build
(requires dotnet 3.1+ cli)F5
Enter
on a the lineHelloWorld.UserInterfaceImpl.HelloWorld.UserInterface.Display()@UserInterfaceImpl.cs:17
F9
:call vimspector#ListBreakpoints()
:call bimspector#Reset()
then:call vimspector#ListBreakpoints()
againF5
and run:call vimspector#ListBreakpoints()
a last timeExpected behaviour
I expected to see the two correct breakpoints when running
call vimspector#ListBreakpoints()
from the debugging tabActual behaviour
I see the two incorrect breakpoints when running
call vimspector#ListBreakpoints()
from the debugging tab, yet when I run this after runningcall vimspector#Reset()
, the breakpoints are correct. If I launch another debugging session, the two breakpoints shown in the quicklist will be incorrect againOutput from Server UI diagnostic tabs
```javascript Request for '{'command': 'stackTrace', 'arguments': {'threadId': 6836}, 'seq': 6, 'type': 'request'}' failed: Failed command 'stackTrace' : 0x80131302 Response: {'command': 'stackTrace', 'message': "Failed command 'stackTrace' : 0x80131302", 'request_seq': 6, 'seq': 22, 'success': False, 'type': 'response'} Paused in thread 6836 due to breakpoint ```Vimspector log (~/.vimspector.log)
``` 2020-09-27 17:45:39,199 - INFO - User requested start debug session with {} 2020-09-27 17:45:39,199 - DEBUG - Reading gadget config: C:\Users\tranm\Desktop\tools\vim\pack\plugins\start\vimspector\gadgets\windows\.gadgets.json 2020-09-27 17:45:39,201 - DEBUG - Reading gadget config: None 2020-09-27 17:45:39,202 - DEBUG - Reading configurations from: None 2020-09-27 17:45:39,202 - DEBUG - Reading configurations from: C:\Users\tranm\Desktop\projects\vimspector_bug_repro\.vimspector.json 2020-09-27 17:45:39,202 - INFO - Configuration: {"default": true, "adapter": "netcoredbg", "configuration": {"request": "launch", "program": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro/details/startup/bin/Debug/netcoreapp3.1/console.dll"}} 2020-09-27 17:45:39,202 - INFO - Adapter: {"attach": {"pidProperty": "processId", "pidSelect": "ask"}, "command": ["C:\\Users\\tranm\\Desktop\\tools\\vim\\pack\\plugins\\start\\vimspector\\gadgets\\windows/netcoredbg/netcoredbg", "--interpreter=vscode"], "name": "netcoredbg"} 2020-09-27 17:45:39,496 - INFO - Starting debug adapter with: {"attach": {"pidProperty": "processId", "pidSelect": "ask"}, "command": ["C:\\Users\\tranm\\Desktop\\tools\\vim\\pack\\plugins\\start\\vimspector\\gadgets\\windows/netcoredbg/netcoredbg", "--interpreter=vscode"], "name": "netcoredbg"} 2020-09-27 17:45:39,516 - INFO - Debug Adapter Started 2020-09-27 17:45:39,516 - DEBUG - Sending Message: {"command": "initialize", "arguments": {"adapterID": "netcoredbg", "clientID": "vimspector", "clientName": "vimspector", "linesStartAt1": true, "columnsStartAt1": true, "locale": "en_GB", "pathFormat": "path", "supportsVariableType": true, "supportsVariablePaging": false, "supportsRunInTerminalRequest": true}, "seq": 0, "type": "request"} 2020-09-27 17:45:39,623 - DEBUG - Message received: {'body': {'capabilities': {'supportTerminateDebuggee': True, 'supportsConditionalBreakpoints': True, 'supportsConfigurationDoneRequest': True, 'supportsFunctionBreakpoints': True}}, 'event': 'capabilities', 'seq': 1, 'type': 'event'} 2020-09-27 17:45:39,623 - DEBUG - Message received: {'body': {}, 'event': 'initialized', 'seq': 2, 'type': 'event'} 2020-09-27 17:45:39,624 - DEBUG - Sending Message: {"command": "setBreakpoints", "arguments": {"source": {"name": "Message.cs", "path": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\entities\\Message.cs"}, "breakpoints": [{"line": 10}]}, "sourceModified": false, "seq": 1, "type": "request"} 2020-09-27 17:45:39,624 - DEBUG - Sending Message: {"command": "setBreakpoints", "arguments": {"source": {"name": "UserInterfaceImpl.cs", "path": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\details\\ui\\UserInterfaceImpl.cs"}, "breakpoints": []}, "sourceModified": false, "seq": 2, "type": "request"} 2020-09-27 17:45:39,624 - DEBUG - Sending Message: {"command": "setExceptionBreakpoints", "arguments": {"filters": []}, "seq": 3, "type": "request"} 2020-09-27 17:45:39,624 - DEBUG - Message received: {'body': {'supportTerminateDebuggee': True, 'supportsConditionalBreakpoints': True, 'supportsConfigurationDoneRequest': True, 'supportsFunctionBreakpoints': True}, 'command': 'initialize', 'request_seq': 0, 'seq': 3, 'success': True, 'type': 'response'} 2020-09-27 17:45:39,624 - DEBUG - LAUNCH! 2020-09-27 17:45:39,624 - DEBUG - Sending Message: {"command": "launch", "arguments": {"request": "launch", "program": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro/details/startup/bin/Debug/netcoreapp3.1/console.dll", "name": "test"}, "seq": 4, "type": "request"} 2020-09-27 17:45:39,629 - DEBUG - Message received: {'body': {'breakpoints': [{'id': 1, 'line': 10, 'message': '', 'verified': False}]}, 'command': 'setBreakpoints', 'request_seq': 1, 'seq': 4, 'success': True, 'type': 'response'} 2020-09-27 17:45:39,629 - DEBUG - Breakpoints at this point: { "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\details\\ui\\UserInterfaceImpl.cs": [ { "id": 1, "line": 10, "message": "", "verified": false, "source": { "name": "UserInterfaceImpl.cs", "path": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\details\\ui\\UserInterfaceImpl.cs" } } ] } 2020-09-27 17:45:39,630 - DEBUG - Message received: {'body': {'breakpoints': []}, 'command': 'setBreakpoints', 'request_seq': 2, 'seq': 5, 'success': True, 'type': 'response'} 2020-09-27 17:45:39,630 - DEBUG - Breakpoints at this point: { "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\details\\ui\\UserInterfaceImpl.cs": [ { "id": 1, "line": 10, "message": "", "verified": false, "source": { "name": "UserInterfaceImpl.cs", "path": "C:\\Users\\tranm\\Desktop\\projects\\vimspector_bug_repro\\details\\ui\\UserInterfaceImpl.cs" } } ] } 2020-09-27 17:45:39,630 - DEBUG - Message received: {'command': 'setExceptionBreakpoints', 'message': "Failed command 'setExceptionBreakpoints' : 0x80004001", 'request_seq': 3, 'seq': 6, 'success': False, 'type': 'response'} 2020-09-27 17:45:39,630 - ERROR - Request failed: Failed command 'setExceptionBreakpoints' : 0x80004001 2020-09-27 17:45:39,630 - DEBUG - Sending Message: {"command": "configurationDone", "seq": 5, "type": "request"} 2020-09-27 17:45:39,630 - DEBUG - Message received: {'body': {}, 'command': 'launch', 'request_seq': 4, 'seq': 7, 'success': True, 'type': 'response'} 2020-09-27 17:45:39,747 - DEBUG - Message received: {'body': {}, 'command': 'configurationDone', 'request_seq': 5, 'seq': 8, 'success': True, 'type': 'response'} 2020-09-27 17:45:39,747 - DEBUG - Sending Message: {"command": "threads", "seq": 6, "type": "request"} 2020-09-27 17:45:39,847 - DEBUG - Message received: {'body': {'threads': [{'id': 5768, 'name': 'Environemnt
Version of Vimspector: 42b79d8cbd7e26d4573bc3c0f3cf5aa33bdc602d
Output of
vim --version
which vim
orwhich nvim
::py3 print( __import__( 'sys' ).version )
::py3 import vim
::py3 import vimspector
::checkhealth
Declaration