I recently create an app using Python in VS Code. I made some modifications and now the Run button in the top left is gone. I can only run the app with the debug mode. I already try to click the little bug as it was suggested on another post. It is doing the same on my macbook when I share my code with Github. If I run the same code in a new file the Run button came back.
Do you have any way to solve this problem without having to create a new file?
"Tools > Debugger > Show run to click button in editor" option is turned on.
To bring up the Run and Debug view, select the Run and Debug icon in the Activity Bar on the side of VS Code. You can also use the keyboard shortcut Ctrl+Shift+D.
Run the program To start building the program, press the green Start button on the Visual Studio toolbar, or press F5 or Ctrl+F5. Using the Start button or F5 runs the program under the debugger. Visual Studio attempts to build and run the code in your project.
You have two options here:
Search for Python in Microsoft Visual Studio Code's Extension: Marketplace and hit on install.
Search for Jupyter in Microsoft Visual Studio Code's Extension: Marketplace and hit on install.
Or you can use your terminal or command prompt to install them. Open the terminal or command prompt and write these commands there.
Install Microsoft Python extension,
code --install-extension ms-python.python
Install Microsoft Jupyter extension ,
code --install-extension ms-toolsai.jupyter
Search for Code Runner in Microsoft Visual Studio Code's Extension: Marketplace and hit on install.
Or you can use your terminal or command prompt to install it. Open the terminal and write the command.
Install Code Runner,
code --install-extension formulahendry.code-runner
You must go with the first option by Microsoft. If you go with both the options, you install Code Runner and Microsoft Python and Jupyter extensions then the Microsoft Python extension will only work if you disable Code Runner.
Code Runner is a good extension for C, C++, Java, Javascript, Perl, ... but for Python Microsoft Python and Jupyter extension is the best.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With