简体   繁体   English

无法通过 pip install 安装 pyautogui,错误 1

[英]Unable to install pyautogui through pip install with error1

I'm trying to install pyautogui through code 'pip install pyautogui' But the program always give me an error like following I started Visual Studio Code with Administration Authority我正在尝试通过代码 'pip install pyautogui' 安装 pyautogui 但程序总是给我一个错误,就像下面我用管理权限启动了 Visual Studio Code

========================================================================================= ================================================== ========================================

(.venv) C:\Users\USer\Desktop\pythoncode>pip install pyautogui
Collecting pyautogui
  Using cached https://files.pythonhosted.org/packages/19/ef/438d80abd396fd2d124bd37c07c765f913723c54197c4c809d85c8ff5a43/PyAutoGUI-0.9.41.tar.gz
Collecting pymsgbox (from pyautogui)
  Using cached https://files.pythonhosted.org/packages/b6/65/86379ede1db26c40e7972d7a41c69cdf12cc6a0f143749aabf67ab8a41a1/PyMsgBox-1.0.6.zip
Collecting PyTweening>=1.0.1 (from pyautogui)
  Using cached https://files.pythonhosted.org/packages/b9/f8/c32a58d6e4dff8aa5c27e907194d69f3b57e525c2e4af96f39c6e9c854d2/PyTweening-1.0.3.zip
Requirement already satisfied: Pillow in c:\users\user\desktop\pythoncode\.venv\lib\site-packages (from pyautogui) (5.4.1)
Collecting pyscreeze (from pyautogui)
  Using cached https://files.pythonhosted.org/packages/f3/27/073bf07400943e38b06ba40def60ec489d114fd7356c2db5a2f793454312/PyScreeze-0.1.19.tar.gz
Collecting pygetwindow (from pyautogui)
  Using cached https://files.pythonhosted.org/packages/01/ed/56d4a369c6e18f6b239d9ef37b3222ba308bfebf949571b2611ff7d64f1d/PyGetWindow-0.0.4.tar.gz
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\USer\AppData\Local\Temp\pip-install-wupkdbtd\pygetwindow\setup.py", line 11, in <module>
    long_description = fh.read()
UnicodeDecodeError: 'cp949' codec can't decode byte 0xe2 in position 903: illegal multibyte sequence

----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\USer\AppData\Local\Temp\pip-install-wupkdbtd\pygetwindow\

========================================================================================= ================================================== ========================================

I use 32bit windows and 32bit python 3.7我使用 32 位 Windows 和 32 位 python 3.7

I already upgrade my pip with code pip install --upgrade pip .(current version is 19.0.2 now)我已经用代码pip install --upgrade pip --upgrade pip install --upgrade pip升级了我的 pip 。(当前版本是 19.0.2 现在)

And I have tried a prompt with administration authority and type pip install pyautogui but Prompt also gave me the same error :我尝试了具有管理权限的提示并键入pip install pyautogui但提示也给了我同样的错误:

Command "python seup.py egg_info" failed with error code 1 in C:\Users\USer\AppData\Local\Temp\pip-install-e2r19eza\pygetwindow\

I already try the solution that the follwing link suggets but I failed "pip install unroll": "python setup.py egg_info" failed with error code 1 I failed to do easy_install -U setuptools with an error:我已经尝试了以下链接建议的解决方案,但我失败了“pip install unroll”:“python setup.py egg_info” failed with error code 1 I failed to do easy_install -U setuptools with an error:

WinError 5] Access is denied :  'c:\\users\\user\\desktop\\pythoncode\\.venv\\Scripts\\easy_install.exe'

Please share your wisdom to the beginner请把你的智慧分享给初学者

尝试以管理员身份安装。

pip install pyautogui

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM