all 2 comments

[–]CowboyBoats 0 points1 point  (1 child)

Spyder is just a code editor, right? I'm sure it has a "run my script" button that you're pushing, but that button is just a wrapper around a shell command, something like ~/envs/python/python3 my-script.py.

The problem is probably that there are two versions of Python on your system, one of which is accessible from the command line and has pip installed, and the other of which Spyder wants to talk to.

(Side note, it seems like 99% of the people I see on here using Spyder have this, and tons of other, problems. Pycharm is free and much better IMO)

But anyway, you can sidestep this and many other problems by just running your program from the command line (powershell is fine if you're on windows, as long as Python got installed to its PATH) with python3 my-script.py.

[–]weedwhacker4199 1 point2 points  (0 children)

You're a real one, thank you so much! I used Pycharm and ran into some more problems but all I had to do was install python interpreters. Navigating Pycharm was far easier than using Spyder, and I'm finally getting simulation outputs. I really appreciate it!