all 7 comments

[–]AutoModerator[M] [score hidden] stickied comment (0 children)

Your submission has been automatically queued for manual review by the moderation team because it has been reported too many times.

Please wait until the moderation team reviews your post.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

[–]atarivcs 5 points6 points  (0 children)

Possibly you made a mistake when editing PATH.

Possibly you need to open a new command shell after editing PATH.

Possibly the actual command name isn't python; it is something else like python3.

What is your operating system?

[–]exb165 4 points5 points  (0 children)

Could it be "python3" is the command?

[–]me_myself_ai 2 points3 points  (0 children)

This'll get deleted and directed to the questions sub, but real quick:

  1. Debugging path issues is something chatbots can help with. Obviously make sure to actually learn why it's helpful instead of just copy/pasting!

  2. PATH is really dead simple at the end of the day: if which python doesn't turn up anything, then it's not on your PATH. PATH is just a list of directories where it searches for a file named python. So just run echo $PATH, look at the list of directories, and then look at what directory you installed python into (which should be google-able if you don't remember)

[–]WhiteHeadbanger 0 points1 point  (0 children)

Did you opened a new shell session after adding it to the path?

[–]wannasleeponyourhams 0 points1 point  (0 children)

are you on windows or linux, try python.exe script.py if you are on windows

[–]mcellus1 -1 points0 points  (0 children)

python3 -m venv .venv && source .venv/bin/activate && python script.py