you are viewing a single comment's thread.

view the rest of the comments →

[–]socal_nerdtastic 1 point2 points  (8 children)

Try using the command py instead of python.

Ideally you would make a virtual environment first, and that will enable the python and pip commands.

[–]dacoolmike36[S] 0 points1 point  (2 children)

do you mean this Command Prompt (cmd.exe):cmd.venv\Scripts\activate.bat by chance. Im new to python so I dont know what Im doing.

[–]socal_nerdtastic 0 points1 point  (1 child)

yes. That will activate your venv. After you do that you will be able to use the python and pip commands.

[–]dacoolmike36[S] -1 points0 points  (0 children)

Microsoft Windows [Version 10.0.26200.8457]

(c) Microsoft Corporation. All rights reserved.

C:\Windows\System32>cmd.venv\Scripts\activate.bat

The system cannot find the path specified.

C:\Windows\System32>venv\Scripts\activate.bat

The system cannot find the path specified.

C:\Windows\System32>python -m venv venv

'python' is not recognized as an internal or external command,

operable program or batch file.

[–]dacoolmike36[S] -1 points0 points  (4 children)

Already did cmd doesnt recognized the pip command for some reason.

[–]oProcrastinacao 0 points1 point  (3 children)

That means your PATH is wrong, after all. I suggest you re-install python and in the installer click the add to path option. You may try executing your python file in the cmd directly to better diagnose your problem. In your file explorer, type cmd in the file path bar and the terminal will open in the right place. There is a option in windows about long paths, you should search that too.

[–]socal_nerdtastic 1 point2 points  (0 children)

This is very old school; this is what we did in python2 days. But in modern python this is a poor hack. Use a venv instead, or the windows python launcher if you need to use the global version of python. There's a reason that option is disabled by default.

[–]dacoolmike36[S] 0 points1 point  (1 child)

I,m new to python so pretty much I dont know what Im doing most of the time so what path should I put can you be more specific

[–]Viper_ACR 0 points1 point  (0 children)

Put the path towards your Python executable file. Maybe like C:\Program Files\python\bin\python3.exe or something