PIP --upgrade不工作Python3.4.4

问题描述 投票:1回答:2

我看了一些关于这一点,并没有帖子似乎解决它。我initally开始了关于Python 3.5,听说有与PIP几个尚未解决的问题,所以我卸载并重新安装的Python 3.4.4 -

我想用pyautogui的工作任务,但是当我尝试Python3.4.4安装后直接安装pyautogui它告诉我的PIL模块无法找到。我在另一篇文章读来安装3.4.4和更新点子,然后安装pyautogui。酷,所以我安装3.4.4,我需要升级点子。所以,我在进入

Scripts\pip.exe install --upgrade pip

从根文件夹的命令行。每次我得到这个

 Exception:
Traceback (most recent call last):
  File "h:\python34\lib\shutil.py", line 527, in move
    os.rename(src, real_dst)
PermissionError: [WinError 32] The process cannot access the file because it is
being used by another process: 'h:\\python34\\scripts\\pip.exe' -> 'C:\\Users\\z
jf\\AppData\\Local\\Temp\\pip-qo75adq9-uninstall\\python34\\scripts\\pip.exe'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "h:\python34\lib\site-packages\pip\basecommand.py", line 211, in main
  File "h:\python34\lib\site-packages\pip\commands\install.py", line 311, in run

  File "h:\python34\lib\site-packages\pip\req\req_set.py", line 640, in install
  File "h:\python34\lib\site-packages\pip\req\req_install.py", line 716, in unin
stall
  File "h:\python34\lib\site-packages\pip\req\req_uninstall.py", line 125, in re
move
  File "h:\python34\lib\site-packages\pip\utils\__init__.py", line 315, in renam
es
  File "h:\python34\lib\shutil.py", line 540, in move
    os.unlink(src)
PermissionError: [WinError 32] The process cannot access the file because it is
being used by another process: 'h:\\python34\\scripts\\pip.exe'

事情是,没有什么是该文件夹中运行。我没有Windows资源管理器打开它,我没有什么访问中有任何文件,而我明明从上一级目录使用命令行运行它。所以我不知道为什么它说pip.exe正在被另一个进程使用。它被运行的唯一的过程本身,如果是这样的问题,那么在世界上你是如何应该升级呢?

**编辑:**每接受的答案,为了得到PIP更新我用过的命令

python -m pip install -U pip

一旦工作,我试图安装pyautogui又一次。它还说,PIL模块找不到。 PIL是Python图像库。我安装了它使用

python -m pip install image

而一旦工作,然后就装pyautogui像这样

python -m pip install pyautogui

python pip python-3.4
2个回答
4
投票

要在Windows上升级PIP谷歌“在Windows上升级点子”或交替在命令提示符中运行以下命令:

python -m pip install -U pip

这是Windows上的已知问题,而它运行的可执行文件不能被覆盖。对不起没有联系方便,但它应该很容易找到更多的细节。


0
投票

问题:您正在使用PIP版本18.1,但版本19.0.1可用。你应该考虑通过升级“蟒蛇-m PIP安装-upgrade点子”命令。

解决方法:为了在Windows升级PIP,你需要打开Windows命令提示符,然后键入/复制下面的命令。请注意,如果你已经添加的Python到Windows路径下面的方法只会工作。别担心,如果你不知道这意味着什么,我会告诉完整的步骤将在下一节升级PIP在Windows中。

python -m pip install --upgrade pip
© www.soinside.com 2019 - 2024. All rights reserved.