python模块未在VS Code中导入

时间:2020-02-17 17:56:14

标签: visual-studio-code

我的可视代码设置有问题。目前,我使用Python,但是ctrl+clickGo to Definiton可以工作。甚至不在同一个班级内。

Problems下,我的所有python文件都出现了类似Unable to import utils之类的错误。

我的settings.json如下:

{
    "python.pythonPath": "~/.virtualenvs/sonyproject/bin/python",
    "python.linting.pylintEnabled": true,

    "python.autoComplete.extraPaths": [
        "/usr/wiss/myname/Code/sonyproject/SonyBody/python_body/**",
        "/usr/wiss/myname/Code/LocalLibs/PythonLibs",
        "${workspaceFolder}/src/**",
        "${workspaceFolder}/**",
        "/usr/wiss/myname/Code/newresearch2/HumanShapePose/DVOApproach/ProjectPoints/src/**",
        "/usr/wiss/myname/Code/newresearch2/HumanShapePose/DVOApproach/ProjectPoints/src/utils/**"
    ],
    "window.zoomLevel": 0,
    "python.analysis.memory.keepLibraryAst": true,
    "python.analysis.memory.keepLibraryLocalVariables": true
}

0 个答案:

没有答案