debugpy.configure(python=) is not properly documented
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 62/100
- Tipo de issue
- Documentación
- Claridad
- Bastante claro
- Estado de actividad
- Tranquilo
- Stack tecnológico
- python
- Área
- documentation
Línea de trabajo
Comience con la documentación de debugpy.configure(python=), junto con la configuración de escucha mediante debugpy.listen y debugpy.wait_for_client. Compruebe cómo se comporta sys.executable en un entorno de Python alojado o embebido y, después, documente la recursión o el fallo de conexión, así como la configuración esperada del ejecutable.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Before creating a new issue, please check the FAQ to see if your question is answered there.
Environment data
- debugpy version: XXX (run
import debugpy; print(debugpy.__version__)if uncertain) - OS and version: XXX
- Python version (& distribution if applicable, e.g. Anaconda): XXX
- Using VS Code or Visual Studio:
Actual behavior
The parent program seemingly recursively gets created and started as a process without any easy way to kill the large number of processes created.
Expected behavior
It attached and works...
Steps to reproduce:
- Embed python into a program using the C API.
- Make a top level script that includes debugpy debugging... import debugpy, debugpy.listen, debugpy.wait_for_client, etc..
- Have parent program run and execute the top level script.
Not sure if this is a bug or is explained elsewhere. I am not going to spend the time to get involved and go through the forum. I am only leaving this here as a "gotcha" for a lonely passerby who ends up in the same scenario. Please edit / move as necessary.
In my use case, I want debugpy debugger support in a hosted (embedded) python environment. The user calls the user program and not python.exe. As such, sys.executable gets set to the exe of the program and not the expected python.exe. Why does this cause an infinite process recursion or fail to connect to the client debugger?

That would be why.
Moral of the story is.. make sure your sys.executable is set to python.exe in the hosted environment before using debugpy with the listening setup.
- Lenguaje dominante
- Python
- Estrellas
- 2.5k
- Forks
- 202
- Merge medio
- 5 d 1 h
- PR fusionados (30 d)
- 1
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de microsoft/debugpy
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
Document "rules"-option Abiertodocumentation
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
Adapter bootstrap fails with ConnectionRefusedError on WSL2 VirtioProxy or hostAddressLoopback Abierto
Dificultad 3/5 1-2 días Aptitud para principiantes 68/100
-
bug
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
Todos los issues de microsoft/debugpy
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
-
enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100