Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In vscode using Python, ctrl+F5 always asks for "select environment"

I installed VSCode, downloaded official Python 3.6.4.

VSCode detected and set the environment right - I do see "python.pythonPath" user setting set correctly.

But, when using VS Code using Ctrl+F5to run a Python file, I am always getting asked for "select environment" and it shows me two options - Python - Python Experimental

What is this "Python Experimental"? How can I get rid of getting interrupted every time I try to run a script?

like image 473
Azz Avatar asked Mar 16 '18 03:03

Azz


People also ask

What does Ctrl F5 do in VSCode?

The Debug: Run (Start Without Debugging) action is triggered with Ctrl+F5 and uses the currently selected launch configuration. Many of the launch configuration attributes are supported in 'Run' mode. VS Code maintains a debug session while the program is running, and pressing the Stop button terminates the program.

How do I select Python environment in VSCode?

To select a specific environment, use the Python: Select Interpreter command from the Command Palette (Ctrl+Shift+P).

How do you activate environment in VS code?

Open Visual Studio Code in your project's folder. Click Yes ; and your venv is ready to go. Open a new terminal within VSCode Ctrl + Shift + P and you'll see that venv is getting picked up; e.g.: (venv) ... Activate.

How do you remove environment from VS code?

Make sure VSCode is using the same environment. The environment folder will show up in the Explorer view. Right click on that folder and select Delete (or click on it, and hit the Delete key on your keyboard). A popup opens for confirmation to move to the recycle bin.


1 Answers

Run > Add Configuration... => Choose one of the two options.

After doing this it will no longer prompt you.

like image 100
Christian Erskine Avatar answered Sep 21 '22 12:09

Christian Erskine