当我使用#!| Run in debugger选项在TextWrangler中调试python代码时,代码在终端中运行,而不是在python调试器中运行。如何配置TextWrangler以使用python调试器?
顺便说一句-使用运行在Mac上的python v3.5 (2880),TextWrangler文件具有.py扩展名,并且被TextWrangler视为python文件;语法突出显示是正确的。
谢谢,杰米
我在VS代码中做了python调试。以下是launch.json文件:
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configuratio
我发现了类似的讨论。但我的问题是,它可以在正常模式下运行python代码。当我作为python -m nmt.py在调试中运行时,我有ImportError: attempted relative import with no known parent package。我的python版本是Python3.7.13。错误来自下面一行。
from . import inference
如何使它在调试中工作?
最近,我按照下面的教程尝试使用VSCode在Docker容器中调试python代码:
我的Dockerfile如下所示:
FROM ubuntu as base
#Do standard image stuff here
#Python Debugger
From base as debugger
RUN pip3 install debugpy
ENTRYPOINT ["python3","-m","debugpy","--listen","0.0.0.0:5678","--wait-for
我正在用Python构建一个应用程序。不久前,我可以毫无问题地调试它,但是在意外地重置了我的VS Code设置之后,我就不能再调试了。每当我尝试调试时,在我尝试导入的第一个已安装的库上都会出现以下错误: Exception has occurred: ModuleNotFoundError No module named
'PySimpleGUI' 当我尝试使用pip3安装库时,我得到消息: Requirement already satisfied: PySimpleGui in c:\users\adassa\appdata\local\packages\pythonso