Questions tagged [vscode-code-runner]

Code Runner is an open-source extension for Visual Studio Code. It enables you to run a variety of languages in Visual Studio Code, with support for every popular programming language including both legacy languages and those that have gained popularity in recent years.

Code Runner is a free, open-source extension for Visual Studio Code.

It enables you to run a variety of languages in Visual Studio Code, with support for every popular programming language including both legacy languages and those that have gained popularity in recent years: C, C++, Java, JavaScript, PHP, Python, Perl, Perl 6, Ruby, Go, Lua, Groovy, PowerShell, BAT/CMD, BASH/SH, F# Script, F# (.NET Core), C# Script, C# (.NET Core), VBScript, TypeScript, CoffeeScript, Scala, Swift, Julia, Crystal, OCaml Script, R, AppleScript, Elixir, Visual Basic .NET, Clojure, Haxe, Objective-C, Rust, Racket, AutoHotkey, AutoIt, Kotlin, Dart, Free Pascal, Haskell, Nim, D.

Resources

240 questions
0
votes
3 answers

Output is shown on Terminal instead of Output section in VS Code

As you can see, there is no output shown in output section. But the output is shown in terminal tab. Can someone help me in getting the output in output tab instead of Terminal tab ?
sukhi
  • 53
  • 1
  • 7
0
votes
2 answers

Basics: Importing a class in groovy

I'm beating my head over this but I can't seem to figure out what I'm doing wrong. I have a folder "myproject" and two files in it - "MyScript.groovy" and "MyClass.groovy". MyClass.groovy package myproject public class MyClass { void…
0
votes
1 answer

Code-Runner: /bin/sh: cscript: command not found

I'm on Linux and currently trying to run a simple Hello World-program in C# using visual studio code. The VSC for Linux, Arch Linux to be precise, is 'code'. I installed the extension 'Code Runner', but everytime I click on the 'Play/Execute'-Button…
Moth999
  • 1
  • 1
0
votes
1 answer

VScode CodeRunner extension error in printing values in same line in python

I am getting this error while running a simple code using Visual Studio Code's CodeRunner extension while print values in the same line separated using a space in python. for i in range(0,6): print(i, end = ' ') Error: print(i, end = '…
user11502296
0
votes
1 answer

Code Runner extension in VS Code doesn't output code

I have installed the extension Code Runner for VS Code and it doesn't output any code. All that happens is that it goes to the terminal and writes path to file> python -u and path to file again but within "". Nothing is written in output either. I…
0
votes
1 answer

Code Runner extension in VSCode in Ubuntu 20.04 platform is not working with python file

Whenever I try to run the code print(“Hello World”) with Code Runner extension in VSCode in Ubuntu 20.04, it shows the output Command ‘python not found’ But if I right-click in VSCode and choose “Run python file in terminal”, it runs smoothly but…
0
votes
0 answers

How to run a program from VSCode in Windows CMD terminal?

I want to be able to run programs from VSCode directly into External terminal (Windows CMD) and not in integrated terminal of VSCode. i.e. to show output and take inputs from Windows CMD. How do I do that? If there is a way to preferably do the same…
0
votes
1 answer

Python not catching KeyboardInterrupt when stopping with code runner

When stoping the script with ctrl+alt+m python wont catch it as an interruption. I want to execute a cleanup script before exiting. if __name__ == "__main__": try: main() except KeyboardInterrupt: …
Lambda
  • 23
  • 3
0
votes
0 answers

VSCode: Using the code runner extension with mongoose promises

How can I use mongoose promises with the vscode code runner extension. Consider the code below. async function getUsers(){ return await User.find({}).exec() } console.log(getUsers()) //returns Promise { } Why is it returning a…
YulePale
  • 6,688
  • 16
  • 46
  • 95
0
votes
1 answer

Vs Code: How can I use the run code command to query my database?

In Vs Code there is a play icon on the top right of the window that when clicked runs the code in the opened file. I have a development server opened on my laptop. Can I query my Db with the run code command? For example, I have a file with code as…
YulePale
  • 6,688
  • 16
  • 46
  • 95
0
votes
1 answer

Unable to run node js code in visual studio code using code runner plugin

When I am trying to run node js code in visual studio code. I am getting below error. Object Expected. Code 800A138F. Source : Microsot JScript runtime error. Note: I am using Windows 10 and visual studio code and code runner plugin Error Image-…
0
votes
0 answers

Threading stops main program in Python3

Hey I am runnig my python code under Linux on a Raspberry Pi and it consists of a main.py file that opens threads to do various tasks For more insights: my filestructure looks like this: main.py modules ----controller.py …
0
votes
1 answer

Is possible to configure python to use full path with spaces?

I have question about vscode, venv and code runner My setting looks like: "python.pythonPath": "/Library/Frameworks/Python.framework/Versions/3.8/bin/python3" "code-runner.executorMap": { "python": "$pythonPath -u $fullFileName " } as select…
0
votes
1 answer

VS Code Code runner extension: Struggling to add Python PATH to settings.json due to whitespace

I am trying to get Code Runner to work on VS code on my Windows computer (although I use WSL most of my work involving Python). I have installed Python using Anaconda C:\\Users\\FirstName LastName\\anaconda3\\python.exe You might notice the…
Marielle Dado
  • 147
  • 1
  • 11
0
votes
1 answer

VScode-Code-Runner returns only directory and no output

I have installed Code Runner and i have made the following setup on the Executer Map { "explorer.confirmDelete": false, "[html]": { "editor.defaultFormatter": "vscode.html-language-features" }, "[javascript]": { …