microsoft / microsoft/vscode-python-debugger
No Config Debugging errors when multiple vscode windows are open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 181
- Forks
- 126
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 3
Description
If I use the no config debugging feature with multiple vscode windows open, all of them try to start debugging. Whichever is first suceeds and the rest throw a Server[pid=xxxx] is already being debugged error.
The cause for this is that the extension watches the .noConfigDebugAdapterEndpoints dir and starts debugging if any file appears in it not just if the specified file (VSCODE_DEBUGPY_ADAPTER_ENDPOINTS) is created. Each window has a separate endpoint file in the .noConfigDebugAdapterEndpoints dir, but due to watching for any file, every window will start debugging.
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 in src/extension/noConfigDebugInit.ts around lines 95-97 and read how the .noConfigDebugAdapterEndpoints directory is watched. Confirm that debugging starts only when the endpoint file named by VSCODE_DEBUGPY_ADAPTER_ENDPOINTS is created, so separate VS Code windows do not react to one another's files.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- devtools
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100