Activating Anaconda Environment in VsCode

后端 未结 10 1036
囚心锁ツ
囚心锁ツ 2020-11-30 22:32

I have Anaconda working on my system and VsCode working, but how do I get VsCode to activate a specific environment when running my python script?

10条回答
  •  囚心锁ツ
    2020-11-30 23:08

    If Anaconda is your default Python install then it just works if you install the Microsoft Python extension.

    The following should work regardless of Python editor or if you need to point to a specific install:

    In settings.json edit python.path with something like

    "python.pythonPath": "C:\\Anaconda3\\envs\\py34\\python.exe"
    

    Instructions to edit settings.json

提交回复
热议问题