VScode和WinPython

时间:2018-02-02 20:30:27

标签: python visual-studio-code vscode-settings

我尝试在VSode的Windows 10 Pro上使用WinPython-64bit-3.6.3.0Qt5。 Winpython安装在C:\ Users \ Public \ WinPython-64bit-3.6.3.0Qt5中。在我的用户设置文件中,但我无法在可用的python解释器和python环境列表中看到WinPython。可能有什么不对。我也尝试使用“\”

{
    "terminal.integrated.shell.windows": "C:\\Program Files\\Git\\bin\\bash.exe",

    "python.pythonPath": "C:/Users/Public/WinPython-64bit-3.6.3.0Qt5/python-3.6.3.amd64/python.exe"
}

感谢任何提示。

2 个答案:

答案 0 :(得分:2)

您需要指定文件夹的路径,而不是python.exe。与WinPython-64bit-3.6.3.0Qt5\\python-3.6.3.amd64

一样

另见https://github.com/Microsoft/vscode-python/issues/784

答案 1 :(得分:-1)

maybe another approach, "one-winpython-at-a-time" can be:

- launch "winpython command prompt"

- type "code"+<Enter> ... VSCode starts with the WinPython-augmented path, 

- type <Shift>+<Crtl>+"P" and select the current python executable in the loop


advantage: 

- any terminal created via VScode during the session has the WinPython-augmented path,

- so you can type: "sqlite_bro", or "ptipython" or "jupyter lab" or "npm" in the terminal