1、新建一个python项目 2、打开launch.json文件 3、修改lanuch.json文件为: { "version": "0.2.0", "configurations": [ { "name": "Python", "type": "python", "request": "launch", "stopOnEntry": true, "pythonPath": "${config:python.pythonPath}", "program": "${file}", "cwd": "...
当时在VSCode上运行,会报错:ModuleNotFoundError: No module named ‘common’ VSCode上2种运行方式都会报错: 用Ctrl+F5或F5去运行,结果如下: 添加图片注释,不超过 140 字(可选) 2. 右键点击py文件内容,选择“Run Python File in Terminal”,一样的报错 ...