microsoft / microsoft/vscode-python-debugger

No Config Debugging errors when multiple vscode windows are open

未關閉
#916 5 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

triage-needed verification-needed
主要語言
TypeScript
星號
181
分支
126
平均合併
2 天 3 小時
30 天內合併 PR
3

描述

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.

https://github.com/microsoft/vscode-python-debugger/blob/d7b96430e7dda95cc3d6565364e3639a2b9501c3/src/extension/noConfigDebugInit.ts#L95-L97

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

從 src/extension/noConfigDebugInit.ts 第 95-97 行附近開始,閱讀 .noConfigDebugAdapterEndpoints 目錄是如何被監視的。確認只有在建立了由 VSCODE_DEBUGPY_ADAPTER_ENDPOINTS 指定的端點檔案時才會開始偵錯,從而使彼此獨立的 VS Code 視窗不會對對方的檔案作出反應。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
typescript
領域
devtools
Issue 類型
缺陷
難度
2/5
預估耗時
1-3 小時
活躍度
停滯
描述清晰度
描述清楚
新手友好度
45/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。