Cannot set remote breakpoints in Visual Studio Community 2022 (Version 17.9.3)
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 35/100
Direzione di ricerca
Inizia da debugpy/_vendored/pydevd/pydevd_file_utils.py, in particolare da set_ide_os(os), e confronta i log allegati di adapter, pydevd e server con i passaggi di traduzione dei percorsi riportati. Riproduci il remote attach da Windows a Ubuntu usando gli ambienti elencati e analizza la conversione delle barre intorno al percorso tradotto. L’attività è completata quando sia i breakpoints impostati prima della connessione sia quelli impostati dopo la connessione vengono risolti in /home/shamada/debug/b.py invece di segnalare che il file non esiste.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Symptoms
Remote debugging using VS2022+debugpy does not work properly.
The remote connection is successful, but Breakpoint cannot be set.
Environmental Data
Client environment
- Windows-10
- Visual Studio Community 2022 (ver 17.9.3)
- debugpy 1.8.0
- workdir: \10.123.36.238\shamada\debug\
Server environment
- Ubuntu-22.0.4
- Python 3.11.5
- debugpy 1.8.0
- workdir: /home/shamada/debug/
Execution steps and results
Execution steps
[server side]
export DEBUGPY_LOG_DIR="/home/shamada/debug"
export DEBUG_PYDEVD_PATHS_TRANSLATION=1
export PATHS_FROM_ECLIPSE_TO_PYTHON='[["\\\\10.123.36.238\\shamada\\", "/home/shamada/"]]'
conda activate py311a
python -Xfrozen_modules=off -m debugpy --wait-for-client --listen 0.0.0.0:5678 b.py
[cliennt side]
execute "attach to process"
execute "python remote (debugpy)"
Results
Pre-set breakpoints will be disabled.
Breakpoints set after connection are also disabled.
Both breakpoints are given the error message "Breakpoint in file that does not exist."
Investigation
debugpy.pydevd.log contains logs like the following.
0.00s - Request for breakpoint in: \\10.123.36.238\shamada\debug\b.py line: 3
0.00s - pydev debugger: replacing to server: \\10.123.36.238\shamada\debug\b.py
0.00s - pydev debugger: sent to server: /home/shamada/debug\b.py - matched prefix: \\10.123.36.238\shamada\
0.00s - Breakpoint (after path translation) in: /home/shamada/debug\b.py line: 3
0.00s - os.path.exists('/home/shamada/debug\\b.py') returned False.
It seems that the cause is that slashes and backslashes are not converted properly in path mapping.
Please see the attached file for all logs.
debugpy.adapter-4104855.log
debugpy.pydevd.4104847.log
debugpy.server-4104847.log
Additional attempts
Referring to the previous issue below, I modified the system file below on both the client and server.
Cannot set remote breakpoints in Visual Studio Community 2019 (Version 16.6.1)
File: debugpy/_vendored/pydevd/pydevd_file_utils.py
Location: in set_ide_os(os) function
Add the following.
os = 'WINDOWS'
The symptoms did not change.
- Lingua principale
- Python
- Stelle
- 2.5k
- Fork
- 202
- Merge medio
- 5g 1h
- PR unite (30g)
- 1
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di microsoft/debugpy
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
Document "rules"-option Apertadocumentation
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
-
documentation
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
-
Adapter bootstrap fails with ConnectionRefusedError on WSL2 VirtioProxy or hostAddressLoopback Aperta
Difficoltà 3/5 1-2 giorni Idoneità per principianti 68/100
Tutte le issue di microsoft/debugpy
Issue simili
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
stephrobert/dsoxlab#238 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
sublimehq/package_control#1780 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
nwg-piotr/nwg-displays#145 ·