r/learnpython • u/cloudiimofo • Jun 12 '24
Python works, "py" doesn't
I'm running a windows 10 machine with Python 3.12 installed. For some reason the 'python' command works fine, but 'py' gets me "'py' is not recognized as an internal or external command, operable program or batch file."
I have python installed here: C:\Users[username]\AppData\Local\Programs\Python\Python312
And the python launcher installed here: C:\Windows\py.exe
I've added both locations to my PATH, restarted the machine, but still doesn't work.
Any help is appreciated.
0
Upvotes
1
u/Diapolo10 I write code for a living -- https://github.com/Diapolo10 Jun 12 '24
Well, that's interesting. Can't say I've ever run into an issue like this before.
How did you install Python?
Have you tried uninstalling and reinstalling Python?
What terminal are you using? (CMD, PowerShell, Windows Terminal, Git Bash, ...)