Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
203 views
in Technique[技术] by (71.8m points)

python - 'pip' is not recognized

I tried to install PySide but I got error from the power shell as follows:

pip : The term 'pip' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. At line:1 char:1
+ pip install -U PySide
+ ~~~
+ CategoryInfo : ObjectNotFound: (pip:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

This error shows up on windows when one tries to use pip in the command prompt. To solve this error on windows, you must declare path variable by following these steps:

Step 1 - Right click on My Computer or This PC
Step 2 - Click on Properties
Step 3 - Click on Advanced System Settings

You will find a section called system variables.
Click on Path from the list of variable and values that shows up there.
After clicking on path click edit. You will find a New button in the pop up.
Click that and paste the location of the python35 or python36 folder (The location you specified while installing python) followed by “Scripts” there.
For me its “C:Usersa610580AppDataLocalProgramsPythonPython35-32”
so I type “C:Usersa610580AppDataLocalProgramsPythonPython35-32Scripts”
Click Ok to close all windows and restart your command prompt.
I repeat - restart your command prompt.

Everything should now be working fine! Make sure you don’t disturb anything else in the path variable and follow the aforementioned steps exactly. Alternatively you can watch this video - https://www.youtube.com/watch?v=Jw_MuM2BOuI Happy coding!


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...