Skip to content

Commit 1dd1817

Browse files
bschnurrCopilot
andcommitted
Normalize debugger path aliases and ship shell launcher
Normalize duplicate Windows Path aliases during debug env construction, add the missing debugpy.sh launcher, harden launcher quoting and LF handling, add regression tests, and add reviewCritic guidance. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent 62a5733 commit 1dd1817

11 files changed

Lines changed: 792 additions & 646 deletions

File tree

.gitattributes

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
bundled/scripts/noConfigScripts/debugpy text eol=lf
2+
bundled/scripts/noConfigScripts/debugpy.sh text eol=lf
3+
bundled/scripts/noConfigScripts/debugpy.fish text eol=lf
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
description: "Review critic for vscode-python-debugger. Use when: reviewing a fix, checking regressions, verifying test coverage, or pressure-testing a PR before merge."
3+
tools: [read/readFile, edit/editFiles, execute/runInTerminal, execute/getTerminalOutput, execute/sendToTerminal, search/textSearch, vscode/askQuestions, todo]
4+
---
5+
6+
You are a high-signal review critic for **vscode-python-debugger**.
7+
8+
Focus on correctness, regressions, environment mutation, debug configuration behavior, cross-platform shell integration, and missing tests. Ignore style unless it hides a real bug.
9+
10+
## Review workflow
11+
12+
1. Start with `git status --short` and `git diff --stat`, then read every changed file in scope.
13+
2. Verify each behavior change has a targeted test, or explain exactly why a test is not practical.
14+
3. Prioritize:
15+
- PATH / Path normalization and environment merging
16+
- no-config debugging bootstrap scripts across shells
17+
- debug configuration resolution and workspace behavior
18+
- Windows/macOS/Linux differences that could break launch or attach
19+
4. Report only actionable findings with:
20+
- severity
21+
- affected file or scope
22+
- why it matters
23+
- the missing fix or missing test
24+
5. If the diff looks sound, say so explicitly and cite the tests that support that conclusion.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#! /bin/bash
22
# Bash script
3-
export DEBUGPY_ADAPTER_ENDPOINTS=$VSCODE_DEBUGPY_ADAPTER_ENDPOINTS
4-
python3 $BUNDLED_DEBUGPY_PATH --listen 0 --wait-for-client $@
3+
export DEBUGPY_ADAPTER_ENDPOINTS="$VSCODE_DEBUGPY_ADAPTER_ENDPOINTS"
4+
python3 "$BUNDLED_DEBUGPY_PATH" --listen 0 --wait-for-client "$@"
Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@echo off
2-
:: Bat script
3-
set DEBUGPY_ADAPTER_ENDPOINTS=%VSCODE_DEBUGPY_ADAPTER_ENDPOINTS%
4-
python %BUNDLED_DEBUGPY_PATH% --listen 0 --wait-for-client %*
1+
@echo off
2+
:: Bat script
3+
set "DEBUGPY_ADAPTER_ENDPOINTS=%VSCODE_DEBUGPY_ADAPTER_ENDPOINTS%"
4+
python "%BUNDLED_DEBUGPY_PATH%" --listen 0 --wait-for-client %*
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Fish script
2-
set -x DEBUGPY_ADAPTER_ENDPOINTS $VSCODE_DEBUGPY_ADAPTER_ENDPOINTS
3-
python3 $BUNDLED_DEBUGPY_PATH --listen 0 --wait-for-client $argv
2+
set -x DEBUGPY_ADAPTER_ENDPOINTS "$VSCODE_DEBUGPY_ADAPTER_ENDPOINTS"
3+
python3 "$BUNDLED_DEBUGPY_PATH" --listen 0 --wait-for-client $argv
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# PowerShell script
2-
$env:DEBUGPY_ADAPTER_ENDPOINTS = $env:VSCODE_DEBUGPY_ADAPTER_ENDPOINTS
3-
$os = [System.Environment]::OSVersion.Platform
4-
if ($os -eq [System.PlatformID]::Win32NT) {
5-
python $env:BUNDLED_DEBUGPY_PATH --listen 0 --wait-for-client $args
6-
} else {
7-
python3 $env:BUNDLED_DEBUGPY_PATH --listen 0 --wait-for-client $args
8-
}
1+
# PowerShell script
2+
$env:DEBUGPY_ADAPTER_ENDPOINTS = $env:VSCODE_DEBUGPY_ADAPTER_ENDPOINTS
3+
$os = [System.Environment]::OSVersion.Platform
4+
if ($os -eq [System.PlatformID]::Win32NT) {
5+
python "$env:BUNDLED_DEBUGPY_PATH" --listen 0 --wait-for-client $args
6+
} else {
7+
python3 "$env:BUNDLED_DEBUGPY_PATH" --listen 0 --wait-for-client $args
8+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#! /bin/bash
2+
# Bash script
3+
export DEBUGPY_ADAPTER_ENDPOINTS="$VSCODE_DEBUGPY_ADAPTER_ENDPOINTS"
4+
python3 "$BUNDLED_DEBUGPY_PATH" --listen 0 --wait-for-client "$@"

0 commit comments

Comments
 (0)