microsoft / microsoft/debug-adapter-protocol
GotoTargetsArguments should have thread id
Nobody has claimed this yet.
- Dominant language
- HTML
- Stars
- 1.8k
- Forks
- 173
- Avg merge
- 7d 7h
- Merged PRs (30d)
- 2
Description
Currently GotoTargetsArguments provides only source, line, and column. This is not enough to identify if a given line is valid for the user to move there. It should have threadId as an argument. This will allow the debugger to validate.
# test.py
def foo():
print('A') # suppose thread 2 is stopped here
def bar():
print('B') # suppose thread 1 is stopped here
print('C')
It is valid for thread 1 to move within the same block to print('C'). It is not valid for thread 2 to move to print('C'). There is no way to tell which thread the user wants to move from the arguments of gotoTargets request. The goto request will fail for thread 2, but this can be avoided.
For the screenshot below, I forced a blank targets response. This allows IDE to show changes to cursor indicating the move invalid

Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the GotoTargetsArguments definition and the gotoTargets request in the debug adapter protocol. Trace how the request is validated and handled, then confirm that the protocol can identify the originating thread and reject invalid move targets without relying on a later goto failure.
Written by the indexing model from the issue text.
Assessment
- Domain
- api, devtools
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100