News
That’s how to run a Python script in terminal or CMD. It’s a very straightforward process, but it’s extremely handy if you ever want to quickly carry out a bespoke task.
Open your project file in VS Code, and click on Terminal > New Terminal. Now, run pwd in Terminal to know your path, it should be the path of your project folder. If it’s not, you need to run cd ...
Any Python code is evaluated once the PyScript components finish loading. You can choose whether the output is sent to the DOM (use pyscript.display), or to an embedded terminal.
Results that may be inaccessible to you are currently showing.
Hide inaccessible results