I’m using python 3.10.7 on VS Code and often when I run my files (In the terminal using CodeRunner), it does print the output of the files but just prints the error almost every time and I want to know what it means and what I can do about it.
script : The term 'script' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that ncluded, verify that
the path is correct and try again.
At line:1 char:1
+ script -a /tmp/extension/2022911/Users/terLog
+ ~~~~~~
+ CategoryInfo : ObjectNotFound: (script:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
I’m guessing it’s something to do with coderunner "/tmp/extension/2022911/Users/terLog
" but honestly I’m very confused, it’s been happening for about a month.
2
Answers
Welcome to Stack Overflow!
You seem to be using a nonexistent cmdlet called ‘script’, that is what is causing the problem.
I suggest trying to use
or
, whichever works for you.
Install python extension and use the following way(The upper right corner of the vscode interface) to run python file: